Problem with "sleuth_prep" - 'kal_dirs' (sample_to_covariates) must be a data.frame
I am running Sleuth, but facing the following issue when reaching the "so <- sleuth_prep". the Kir_dirs giving me the following results;
> kal_dirs
SRR493367
"~/Desktop/my_lab/Test/analysis/bears_iplant/results/paired/SRR493367/kallisto"
SRR493368
"~/Desktop/my_lab/Test/analysis/bears_iplant/results/paired/SRR493368/kallisto"
> so <- sleuth_prep(kal_dirs, s2c, ~ condition, target_mapping = t2g)
Error in sleuth_prep(kal_dirs, s2c, ~condition, target_mapping = t2g) :
'kal_dirs' (sample_to_covariates) must be a data.frame
How can fix this Error.
• 1,658 views
•
link
1 answer
Error is clear kal_dirs must be a data.frame with "sample" and "path" columns, maybe try:
kal_dirs_fixed <- data.frame(sample = names(kal_dirs), path = kal_dirs)
so <- sleuth_prep(kal_dirs_fixed, s2c, ~ condition, target_mapping = t2g)
sample_to_covariates a data.frame which contains a mapping from sample (a required column) to some set of experimental conditions or covariates. The column path is also required, which is a character vector where each element points to the corresponding kallisto output directory. The column sample should be in the same order as the corresponding entry in path
• 0 views
•
link
Log in to answer this question.