Skip to contents

Core DAF Functionality

Core functions for working with Daf objects

Daf()
Daf (Data Axes Format) S3 object
is_daf()
Check if object is a Daf
print(<Daf>)
Print method for Daf objects
description()
Get description of a Daf object
`[`(<Daf>)
Extract results from a Daf object using a query
setup_daf()
Set up of the Julia environment needed for DataAxesFormats and TanayLabUtilities
use_default_julia_environment()
Use default or custom Julia environment
install_daf_packages()
Install Julia packages needed for DataAxesFormats and TanayLabUtilities
load_daf_packages()
Load Julia packages needed for DataAxesFormats and TanayLabUtilities
name()
Gets the name of a Daf object

Example Data

Functions for loading example data

example_cells_daf()
Load example cells data into a Daf object
example_metacells_daf()
Load example metacells data into a Daf object
example_chain_daf()
Load example chain data into a Daf object

Data Access and Query

Functions for querying and retrieving data from Daf objects

get_dataframe() get_tidy()
Get a dataframe from a Daf object
get_dataframe_query()
Apply a query to a Daf object and return result as a data.frame
get_matrix()
Get matrix from a Daf object
get_query()
Apply a query to a Daf object
get_scalar()
Get scalar value from a Daf object
get_vector()
Get vector from a Daf object
has_query()
Check if a query can be applied to a Daf object
parse_query()
Parse a query string into a query object
query_result_dimensions()
Get the number of dimensions of a query result
is_axis_query()
Check if a query returns axis entries
query_axis_name()
Get the axis name from a query

Readers and Formats

Reading Daf data from different sources and formats

memory_daf()
Create a Daf object with in-memory storage
h5df()
Create a Daf object with HDF5-based storage
files_daf()
Create a Daf object with file-based storage
h5ad_as_daf()
Convert h5ad file to a Daf object
read_only()
Create a read-only wrapper for a Daf object
chain_reader()
Create a read-only chain wrapper of DafReader objects
complete_daf()
Complete chain of Daf repositories
open_daf()
Open a Daf repository based on path

Writers

Writing Daf data to different formats

daf_as_h5ad()
Convert Daf object to h5ad file
chain_writer()
Create a writable chain wrapper of DafReader objects

Constants and Handlers

Constants and handler functions

ALL_AXES
All axes specifier
ALL_MATRICES
All matrices specifier
ALL_SCALARS
All scalars specifier
ALL_VECTORS
All vectors specifier
VIEW_ALL_AXES
View all axes specifier
VIEW_ALL_DATA
View all data specifier
VIEW_ALL_MATRICES
View all matrices specifier
VIEW_ALL_SCALARS
View all scalars specifier
VIEW_ALL_VECTORS
View all vectors specifier
IGNORE_HANDLER WARN_HANDLER ERROR_HANDLER
Handler types for abnormal operations
inefficient_action_handler()
Set the handler for inefficient matrix access

Axes and Properties

Functions for managing axes and properties in Daf objects

has_axis()
Check if an axis exists in a Daf object
add_axis()
Add axis to a Daf object
delete_axis()
Delete axis from a Daf object
axis_contract()
Create an axis contract specification
axis_dict()
Get dictionary of axis entries to indices
axis_entries()
Get entry names for indices in an axis
axis_indices()
Get indices of entries in an axis
axis_length()
Get length of an axis in a Daf object
axis_vector()
Get vector of axis entries from a Daf object
axis_version_counter()
Get axis version counter
axes_set()
Get set of axis names from a Daf object
matrices_set()
Get set of matrix names for axes in a Daf object
scalars_set()
Get set of scalar names from a Daf object
vectors_set()
Get set of vector names for an axis in a Daf object
has_scalar()
Check if a scalar exists in a Daf object
has_vector()
Check if a vector exists in a Daf object
has_matrix()
Check if a matrix exists in a Daf object
delete_matrix()
Delete matrix from a Daf object
delete_scalar()
Delete scalar from a Daf object
delete_vector()
Delete vector from a Daf object
get_matrix()
Get matrix from a Daf object
get_scalar()
Get scalar value from a Daf object
get_vector()
Get vector from a Daf object
set_matrix()
Set matrix in a Daf object
set_scalar()
Set scalar value in a Daf object
set_vector()
Set vector in a Daf object
relayout_matrix()
Relayout matrix in a Daf object
matrix_version_counter()
Get matrix version counter
vector_version_counter()
Get vector version counter

Query Operations - Element-wise

Element-wise operations that preserve data shape but transform values

Abs()
Abs query operation
Clamp()
Clamp query operation
Convert()
Convert query operation
Fraction()
Fraction query operation
Log()
Log query operation
Round()
Round query operation
Significant()
Significant query operation

Query Operations - Reduction

Reduction operations that reduce dimensions (matrix to vector, vector to scalar)

Sum()
Sum query operation
Mean()
Mean query operation
Median()
Median query operation
Min()
Min query operation
Max()
Max query operation
Var()
Var query operation
VarN()
VarN query operation
Std()
Std query operation
StdN()
StdN query operation
Quantile()
Quantile query operation
CountBy()
CountBy query operation
GroupBy()
GroupBy query operation

Query Operations - Logical

Logical operations for filtering and combining data

And()
And query operation
AndNot()
AndNot query operation
Or()
Or query operation
OrNot()
OrNot query operation
Xor()
Xor query operation
XorNot()
XorNot query operation
IsEqual()
IsEqual query operation
IsGreater()
IsGreater query operation
IsGreaterEqual()
IsGreaterEqual query operation
IsLess()
IsLess query operation
IsLessEqual()
IsLessEqual query operation
IsMatch()
IsMatch query operation
IsNotEqual()
IsNotEqual query operation
IsNotMatch()
IsNotMatch query operation

Query Operations - Selection

Operations for selecting data from axes and properties

Axis()
Axis query operation
Lookup()
Lookup query operation
Names()
Names query operation
AsAxis()
AsAxis query operation
Fetch()
Fetch query operation
IfMissing()
IfMissing query operation
IfNot()
IfNot query operation
MaskSlice()
MaskSlice query operation
SquareMaskColumn()
SquareMaskColumn query operation
SquareMaskRow()
SquareMaskRow query operation

Views and Adapters

Creating views and adapters for Daf objects

adapter()
Invoke a computation on a view of some data set and return the result
viewer()
Create a read-only view of a Daf data set
reconstruct_axis()
Reconstruct implicit axes

Contracts

Contract-based validation for Daf objects

RequiredInput OptionalInput GuaranteedOutput OptionalOutput
Contract Expectation Types
create_contract()
Create a Contract specification
contractor()
Create a contract-aware wrapper for a Daf
contract_docs()
Convert contract to documentation string
verify_contract()
Verify a DAF object against a contract
verify_input()
Verify DAF input against contract
verify_output()
Verify DAF output against contract
print(<DafContract>)
Print method for DafContract
scalar_contract()
Create a scalar contract specification
vector_contract()
Create a vector contract specification
matrix_contract()
Create a matrix contract specification
tensor_contract()
Create a tensor contract specification

Groups

Functions for working with groups of axis entries

group_names()
Generate names for groups of axis entries
compact_groups()
Compact group indices
collect_group_members()
Collect group members from group indices

Data Operations

Operations for transforming and combining Daf objects

concatenate()
Concatenate multiple Daf data sets along some axis
copy_all()
Copy all content from source to destination
copy_axis()
Copy an axis from source to destination
copy_matrix()
Copy a matrix from source to destination
copy_scalar()
Copy a scalar from source to destination
copy_tensor()
Copy a tensor from source to destination
copy_vector()
Copy a vector from source to destination

Utilities

Utility functions for working with Daf objects

empty_cache()
Empty cache in a Daf object
set_seed()
Set a seed both in Julia and R
setup_logger()
Set up a global logger