Beginner & HowTo-flowCore-Example
0
0
Entering edit mode
ms-leipzig • 0
@ms-leipzig-15909
Last seen 5.9 years ago

hallo,

just started using R + flowCore to analyze FCS-files.  In the "flowCore: data structures package for flow cytometry data" - tutorial at page 22 in section 5.2 i found the following example-snippet:

library(flowWorkspace)
fcsfiles <- list.files(pattern = "CytoTrol"
, system.file("extdata", package = "flowWorkspaceData")
, full = TRUE)
fs <- read.flowSet(fcsfiles)

 

If I run this in GStudio I get the following error:

> fcsfiles <- list.files(pattern = "CytoTrol"
+                        , system.file("extdata", package = "flowWorkspaceData")
+                        , full = TRUE)
> fs <- read.flowSet(fcsfiles)
Error in frameList[isFrame] : invalid subscript type 'list'
> 

> sessionInfo()
R version 3.5.0 (2018-04-23)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)

Matrix products: default

locale:
[1] LC_COLLATE=German_Germany.1252  LC_CTYPE=German_Germany.1252    LC_MONETARY=German_Germany.1252
[4] LC_NUMERIC=C                    LC_TIME=German_Germany.1252    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] flowWorkspace_3.28.1    ncdfFlow_2.26.0         BH_1.66.0-1             RcppArmadillo_0.8.500.0 flowCore_1.46.1        

loaded via a namespace (and not attached):
 [1] pcaPP_1.9-73        Rcpp_0.12.17        plyr_1.8.4          pillar_1.2.2        DEoptimR_1.0-8      compiler_3.5.0     
 [7] RColorBrewer_1.1-2  bindr_0.1.1         tools_3.5.0         zlibbioc_1.26.0     gtable_0.2.0        tibble_1.4.2       
[13] lattice_0.20-35     pkgconfig_2.0.1     rlang_0.2.0         graph_1.57.1        Rgraphviz_2.24.0    parallel_3.5.0     
[19] mvtnorm_1.0-7       hexbin_1.27.2       bindrcpp_0.2.2      gridExtra_2.3       stringr_1.3.1       dplyr_0.7.5        
[25] cluster_2.0.7-1     IDPmisc_1.1.17      tidyselect_0.2.4    stats4_3.5.0        grid_3.5.0          robustbase_0.93-0  
[31] glue_1.2.0          Biobase_2.40.0      data.table_1.11.2   rrcov_1.4-3         R6_2.2.2            XML_3.98-1.11      
[37] latticeExtra_0.6-28 purrr_0.2.4         corpcor_1.6.9       magrittr_1.5        scales_0.5.0        matrixStats_0.53.1 
[43] MASS_7.3-49         BiocGenerics_0.26.0 assertthat_0.2.0    colorspace_1.3-2    KernSmooth_2.23-15  stringi_1.1.7      
[49] flowViz_1.44.0      munsell_0.4.3      

 

Searching in the web I found some comments like "a sub of a vector is a vector again ...". but this doesnt explain this for me.

thanks and best regards

Simon

 


 

 

 

flowcore • 1.5k views
ADD COMMENT
0
Entering edit mode

Hi,

Your sessionInfo() sounds up to date (at least the same as mine). Next time, please do add missing information as a comment of your original question.

In order to track the error, you should check the content of fcsfiles or simply run the following command

list.files(pattern = "CytoTrol", system.file("extdata", package = "flowWorkspaceData"), full = TRUE)

If you got an empty list, something went wrong during your installation of flowworkspace

If you got file names, check that those files are readable by use of your Windows Explorer (I don't mean Internet Explorer)

If it's still OK, my final guess is that the file path contains characters such as umlaut that R may not like.

If so, copy the FCS files to another folder (C:\temp for example) and try again the example code using that directory, that is, replace system.file("extdata", package = "flowWorkspaceData") with "C:/temp".

Be careful with / and \

HTH

ADD REPLY
0
Entering edit mode

Probably you haven't installed flowWorkspaceData package.

ADD REPLY

Login before adding your answer.

Traffic: 846 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6