liana icon indicating copy to clipboard operation
liana copied to clipboard

Error in `*tmp*`@metadata : no applicable method for `@` applied to an object of class "NULL"

Open Flu09 opened this issue 8 months ago • 3 comments

I would appreciate it if you can help me. Not sure how to fix it. 

> tensor <- liana_tensor_c2c(context_df_dict = context_df_dict,
+                            sender_col = "source", # Column name of the sender cells
+                            receiver_col = "target", # Column name of the receiver cells
+                            ligand_col = "ligand.complex", # Column name of the ligands
+                            receptor_col = "receptor.complex", # Column name of the receptors
+                            score_col = 'magnitude_rank', # Column name of the communication scores to use
+                            how='outer',  # What to include across all samples
+                            lr_fill = NaN, # What to fill missing LRs with
+                            cell_fill = NaN, # What to fill missing cell types with
+                            lr_sep='^', # How to separate ligand and receptor names to name LR pair
+                            sort_elements = FALSE, # Whether sorting alphabetically element names of each tensor dim. Does not apply for context order if context_order is passed.
+                            use_available = TRUE,
+                            build_only = FALSE, # set this to FALSE to combine the downstream rank selection and decomposition steps all here
+ )
Building the tensor using magnitude_rank...
100%|██████████| 1/1 [00:03<00:00,  3.65s/it]Estimating ranks...

100%|██████████| 25/25 [09:01<00:00, 21.65s/it]Decomposing the tensor...
The rank at the elbow is: 6

Error in `*tmp*`@metadata : 
  no applicable method for `@` applied to an object of class "NULL"


> context_df_dict
$`4`
# A tibble: 18,919 × 6
   source                          target                          ligand.complex receptor.complex magnitude_rank dataset
   <chr>                           <chr>                           <chr>          <chr>                     <dbl> <chr>  
 1 Oligodendrocytes                Immature neurons                IL1RAPL1       PTPRD                  4.43e-13 4      
 2 Oligodendrocyte precursor cells GABAergic neurons               NLGN1          NRXN3                  6.92e-12 4      
 3 GABAergic neurons               Oligodendrocyte precursor cells NRXN3          NLGN1                  6.92e-12 4      
 4 Oligodendrocytes                Unknown                         IL1RAPL1       PTPRD                  2.84e-11 4      
 5 Oligodendrocytes                Mature neurons                  IL1RAPL1       PTPRD                  5.54e-11 4      
 6 Oligodendrocyte precursor cells Mature neurons                  NLGN1          NRXN3                  1.22e-10 4      
 7 Mature neurons                  Oligodendrocyte precursor cells NRXN3          NLGN1                  1.22e-10 4      
 8 Oligodendrocyte precursor cells Unknown                         NLGN1          NRXN3                  2.72e-10 4      
 9 Unknown                         Oligodendrocyte precursor cells NRXN3          NLGN1                  2.72e-10 4      
10 Oligodendrocyte precursor cells Oligodendrocyte precursor cells NRXN1          NLGN1                  5.13e-10 4      
# ℹ 18,909 more rows
# ℹ Use `print(n = ...)` to see more rows

Flu09 avatar Jun 16 '24 22:06 Flu09