Column number issue Wasbi

58 views
Skip to first unread message

James Lloyd

unread,
Mar 10, 2016, 12:41:37 PM3/10/16
to Sailfish Users Group
Hello,

I am new to Salmon (and fairly new to R) and I wanted to prepare the output for Sleuth. It all seemed very straightforward until I got this error message from prepare_fish_for_sleuth (below). 

> prepare_fish_for_sleuth(salmon_dirs)
Error in setnames(quant, c("target_id", "length", "tpm", "est_counts")) : 
  Can't assign 4 names to a 5 column data.table

I think it is because the .sf file has 5 columns and not 4 but I could be mistaken. I am not sure how to deal with this issue. I could probably delete the EffectiveLength column from the .sf files but that is a guess to what could fix the problem and is hardly and elegant fix. Any suggestions as to what I am doing wrong or if this is a bug? 

Rob

unread,
Mar 10, 2016, 2:12:10 PM3/10/16
to Sailfish Users Group
Hi James,

  First, welcome to the Sailfish / Salmon users group!  Could you tell me what version of Salmon you're using?  There *was* a change in the salmon output format a few versions ago, but Wasabi should auto-detect the correct version.  If you're input has 5 columns (including the effective length), then it 
should be executing this code path (https://github.com/COMBINE-lab/wasabi/blob/master/R/wasabi.R#L84).  There could potentially be an issue if it's mixing and matching versions across the boundary where effective length was introduced into the output.  If this isn't what's going on, I'd be happy to take a look
at one or more of the output files causing the problem to see if I can reproduce & fix it on my end.

--Rob

P.S.  Also make sure that you're using the latest Wasabi package (last update was Jan 19th).

James Lloyd

unread,
Mar 10, 2016, 3:01:29 PM3/10/16
to Sailfish Users Group
Hi Rob,

Thanks for getting back to me so quickly. I appear to be using Salmon version 0.6.1. I downloaded wasabi yesterday using:

devtools::install_github("COMBINE-lab/wasabi")
library('wasabi')

And I checked the version number to be 0.1 so perhaps that could be the problem.

> library(wasabi)
> packageVersion("wasabi")
[1] ‘0.1’

I should note that I downloaded the output files from Salmon which was run on a Ubuntu server only my local machine (a Windows 10 machine) to run the R code, as that is where I have wasabi and sleuth locally installed. I am not sure if that could be the problem. If so, I could try and install wasabi in the server. 

All the best,
James

Rob

unread,
Mar 10, 2016, 3:04:16 PM3/10/16
to Sailfish Users Group
Hi James,

  Theoretically, these versions should all place nice together.  I don't have access to a windows box, so if that is the problem (which seems unlikely), then I would have trouble reproducing the error.  If you have a single output folder that triggers this issue, I'd be happy to take a look.

Best,
Rob

James Lloyd

unread,
Mar 10, 2016, 4:08:07 PM3/10/16
to Sailfish Users Group
I successfully installed wasabi on the server I use and it seems to have worked perfectly. I am not sure why it is not working on my Windows machine but having it working on my linux server is good enough for me. The only thing I can think of it how R in mac vs Unix handles paths with \\ vs /. 

Thanks for the feedback. 

All the best,
James

Rob

unread,
Mar 10, 2016, 4:10:07 PM3/10/16
to Sailfish Users Group
Oh wow; thanks so much for testing that out.  If I'd taken a look at the data, that would, indeed, have been a head-scratcher.  I only have access to linux and OSX boxes, so reproducing a windows-related issue is tough for me.  I'll take a look for places in the Wasabi code where I make assumptions about path separators.

Thanks again!
Rob
Reply all
Reply to author
Forward
0 new messages