Coder Social home page Coder Social logo

thierrygosselin / assigner Goto Github PK

View Code? Open in Web Editor NEW
17.0 5.0 6.0 30.01 MB

Population assignment analysis using R

Home Page: http://thierrygosselin.github.io/assigner

License: GNU General Public License v3.0

R 100.00%
genomics datascience assignment-analysis assignment radseq radseq-data fst gbs genotyping-by-sequencing

assigner's People

Contributors

anne-laureferchaud avatar eriqande avatar idobar avatar thierrygosselin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

assigner's Issues

Syntax error

Hi, I'm really excited about using assigner, but I keep getting an error when trying to run it. It seems to create 'fst.ranked_.tsv' and 'assignment_data_iteration__markers_10_no_imputation.txt" files, but then throws this error. I've run the file in genepop, so I'm relatively sure that it is formatted properly. I've also gotten a different genepop file to run through assigner without problems. Any insight on what might be holding up this file? Below is an example input file.

test.txt

Thanks,
Dan Drinan

library(assigner)
library(reshape2)
library(ggplot2)
library(stringr)
library(stringi)
library(plyr)
library(dplyr) # load this package after plyr to work properly
library(tidyr)
library(readr)
library(adegenet)
library(randomForestSRC)
library(doParallel)
library(foreach)
library(purrr)
library(utils)
library(iterators)
library(stats)
library(stackr)

my_data <-read.genepop("test.gen", ncode = 2) #save your genepop file as a genind object named mydata

Converting data from a Genepop .gen file to a genind object...

File description: #Title: removed loci with 3 alleles

...done.

mytidydata <- tidy_genomic_data(data = my_data)
#######################################################################
###################### stackr::tidy_genomic_data ######################
#######################################################################
Tidying the genind object ...
Scanning for number of alleles per marker...
Data is biallellic
Generating vcf-style coding
Erasing genotype: no
Using markers common in all populations:
Number of markers before = 50
Number of markers removed = 0
Number of markers after (common between populations) = 50
Removing monomorphic markers: yes
Scanning for monomorphic markers...
Number of markers before = 50
Number of monomorphic markers removed = 10
Number of markers after = 40
############################### RESULTS ###############################
Tidy data in your global environment
Data format: tbl_df
Biallelic data
Number of common markers: 40
Number of chromosome/contig/scaffold: no chromosome info
Number of individuals: 276
Number of populations: 8
Computation time: 0 sec
############################## completed ##############################

my_assignment <- assignment_ngs(mytidydata, #specify that your data file
assignment.analysis = "gsi_sim", # specify that the analysis happens in gsi_sim
sampling.method = "ranked", #specify that the assignment should happen using markers with high FST
thl = 10, # specify that you want to use the training-holdout-leave one out assignment method. thl = 1, 1 individual sample is used as holdout. This individual is not participating in the markers ranking.
iteration.method = 10,
subsample = NULL,
#iteration.subsample = 10,
common.markers = TRUE,
marker.number = 10,
verbose = TRUE,
folder = NULL,
keep.gsi.files = TRUE,
random.seed = NULL,
parallel.core = parallel::detectCores() - 1)
#######################################################################
###################### assigner::assignment_ngs #######################
#######################################################################
Assignment analysis with gsi_sim
Map-independent imputations: no
Folder: /home/dan/Dropbox (MERLAB)/Pacific_cod/cod_kristen/assigner/assignment_analysis_method_ranked_no_imputations_20170705@1527/
Scanning for monomorphic markers...
Number of markers before = 40
Number of monomorphic markers removed = 0
Subsampling: not selected
Conducting Assignment analysis with ranked markers
Using thl method, ranking Fst with training samples...
Holdout samples saved in your folder
Starting parallel computations for the assignment analysis: ranked markers
For progress: monitor activity in the folder...
| | 0%, ETA NA
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected
sh: 1: Syntax error: "(" unexpected

Compiling results
Error in bind_rows_(x, .id) : 'getCharCE' must be called on a CHARSXP
In addition: Warning message:
In .assigner_parallel(X = iterations.list, FUN = assignment_ranking, :
scheduled cores encountered errors in user code

Function assignment_mixture no longer available in v0.5.7?

Hi!
I used assigner to to perform assignments on a group of baseline samples a month ago. Now I get a new set of samples of unknown origins, and I would like to assign this batch to the baseline samples. Previously we have the function assignment_mixture to perform such kind of tasks, but it seems this function was disabled in the latest assigner v0.5.7?
Thanks a lot,
Peiwen

Issues using tidy_vcf function

Describe the bug
I have tried to calculate Fst on a vcf file obtained through a "home-made" ddocent pipeline.
To do so, I first need to import and transform the vcf in a tidy data frame in R.

I used the following command:
data <- radiator::tidy_vcf(
data = "Amp_a_TotalSNPs_filtred_without_contigs.haplo.vcf",
strata = "pop_map_Amp_a.txt",
gt = TRUE,
tidy.check = FALSE# skip the test for number of markers, otherwise it ask during tidying...
)

It seems that it recognised my pop strata and the number of individuals in the VCF.
Yet I am getting the following error message at the end (see screenshot)
Screenshot 2020-01-23 at 16 04 31

Thanks in advance for your help,

Laura

Heat map error

Hi Thierry,

I've got the following error when trying to make a heatmap with the assigner 0.5.7:

> heat.fst <- heatmap_fst(fst.ci$pairwise.fst.full.matrix, fst.ci$pairwise.fst.ci.matrix, n.s = TRUE,
+             digits = 3, color.low = "white", color.mid = "grey",
+             color.high = "black", text.size = 4, plot.size = 40,
+             path.folder = NULL, filename = NULL)
Error: Can't join on `x$POP1` x `y$POP1` because of incompatible types.
ℹ `x$POP1` is of type <ordered<09208>>>.
ℹ `y$POP1` is of type <ordered<58a21>>>.
Run `rlang::last_error()` to see where the error occurred.

Details:

> rlang::last_error()
<error/rlang_error>
Can't join on `x$POP1` x `y$POP1` because of incompatible types.
ℹ `x$POP1` is of type <ordered<2bfb4>>>.
ℹ `y$POP1` is of type <ordered<4d8de>>>.
Backtrace:
  1. assigner::fst_WC84(...)
  2. assigner::heatmap_fst(...)
  5. [ `%>%`(...) ] with 7 more calls
 14. dplyr:::left_join.data.frame(., ns, by = c("POP1", "POP2"))
 15. dplyr:::join_mutate(...)
 16. dplyr:::join_rows(x_key, y_key, type = type, na_equal = na_equal)
 17. base::tryCatch(...)
 18. base:::tryCatchList(expr, classes, parentenv, handlers)
 19. base:::tryCatchOne(expr, names, parentenv, handlers[[1L]])
 20. value[[3L]](cond)
Run `rlang::last_trace()` to see the full context.
Warning message:
Internal error: Trace data is not square. 
> rlang::last_trace()
<error/rlang_error>
Can't join on `x$POP1` x `y$POP1` because of incompatible types.
ℹ `x$POP1` is of type <ordered<2bfb4>>>.
ℹ `y$POP1` is of type <ordered<4d8de>>>.
Backtrace:
     █
  1. └─assigner::fst_WC84(...)
  2.   └─assigner::heatmap_fst(...)
  3.     ├─base::suppressWarnings(...)
  4.     │ └─base::withCallingHandlers(...)
  5.     └─`%>%`(...)
  6.       ├─base::withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  7.       └─base::eval(quote(`_fseq`(`_lhs`)), env, env)
  8.         └─base::eval(quote(`_fseq`(`_lhs`)), env, env)
  9.           └─assigner:::`_fseq`(`_lhs`)
 10.             └─magrittr::freduce(value, `_function_list`)
 11.               ├─base::withVisible(function_list[[k]](value))
 12.               └─function_list[[k]](value)
 13.                 ├─dplyr::left_join(., ns, by = c("POP1", "POP2"))
 14.                 └─dplyr:::left_join.data.frame(., ns, by = c("POP1", "POP2"))
 15.                   └─dplyr:::join_mutate(...)
 16.                     └─dplyr:::join_rows(x_key, y_key, type = type, na_equal = na_equal)
 17.                       └─base::tryCatch(...)
 18.                         └─base:::tryCatchList(expr, classes, parentenv, handlers)
 19.                           └─base:::tryCatchOne(expr, names, parentenv, handlers[[1L]])
 20.                             └─value[[3L]](cond)
> devtools::session_info()
─ Session info 
────────
 setting  value                       
 version  R version 4.0.2 (2020-06-22)
 os       Ubuntu 20.04.1 LTS          
 system   x86_64, linux-gnu           
 ─ Packages 
───────────────────────────────────────────────────────
 package          * version  date       lib source                                   
 ade4               1.7-15   2020-02-13 [1] CRAN (R 4.0.2)                           
 adegenet           2.1.3    2020-05-10 [1] CRAN (R 4.0.2)                           
 ape                5.4-1    2020-08-13 [1] CRAN (R 4.0.2)                           
 assertthat         0.2.1    2019-03-21 [1] CRAN (R 4.0.2)                           
 assigner         * 0.5.7    2020-09-11 [1] Github (thierrygosselin/assigner@da61eb8)
 backports          1.1.9    2020-08-24 [1] CRAN (R 4.0.2)                           
 Biobase            2.48.0   2020-04-27 [1] Bioconductor                             
 BiocGenerics       0.34.0   2020-04-27 [1] Bioconductor                             
 BiocManager        1.30.10  2019-11-16 [1] CRAN (R 4.0.2)                           
 Biostrings         2.56.0   2020-04-27 [1] Bioconductor                             
 bitops             1.0-6    2013-08-17 [1] CRAN (R 4.0.2)                           
 boot               1.3-25   2020-04-26 [4] CRAN (R 4.0.0)                           
 broom              0.7.0    2020-07-09 [1] CRAN (R 4.0.2)                           
 callr              3.4.4    2020-09-07 [1] CRAN (R 4.0.2)                           
 class              7.3-17   2020-04-26 [4] CRAN (R 4.0.0)                           
 classInt           0.4-3    2020-04-07 [1] CRAN (R 4.0.2)                           
 cli                2.0.2    2020-02-28 [1] CRAN (R 4.0.2)                           
 cluster            2.1.0    2019-06-19 [4] CRAN (R 4.0.0)                           
 coda               0.19-3   2019-07-05 [1] CRAN (R 4.0.2)                           
 codetools          0.2-16   2018-12-24 [4] CRAN (R 4.0.0)                           
 colorspace         1.4-1    2019-03-18 [1] CRAN (R 4.0.2)                           
 crayon             1.3.4    2017-09-16 [1] CRAN (R 4.0.2)                           
 curl               4.3      2019-12-02 [1] CRAN (R 4.0.2)                           
 data.table         1.13.0   2020-07-24 [1] CRAN (R 4.0.2)                           
 DBI                1.1.0    2019-12-15 [1] CRAN (R 4.0.2)                           
 deldir             0.1-28   2020-07-15 [1] CRAN (R 4.0.2)                           
 desc               1.2.0    2018-05-01 [1] CRAN (R 4.0.2)                           
 devtools         * 2.3.1    2020-07-21 [1] CRAN (R 4.0.2)                           
 digest             0.6.25   2020-02-23 [1] CRAN (R 4.0.2)                           
 dplyr              1.0.2    2020-08-18 [1] CRAN (R 4.0.2)                           
 e1071              1.7-3    2019-11-26 [1] CRAN (R 4.0.2)                           
 ellipsis           0.3.1    2020-05-15 [1] CRAN (R 4.0.2)                           
 expm               0.999-5  2020-07-20 [1] CRAN (R 4.0.2)                           
 fansi              0.4.1    2020-01-08 [1] CRAN (R 4.0.2)                           
 farver             2.0.3    2020-01-16 [1] CRAN (R 4.0.2)                           
 fastmap            1.0.1    2019-10-08 [1] CRAN (R 4.0.2)                           
 fs                 1.5.0    2020-07-31 [1] CRAN (R 4.0.2)                           
 fst                0.9.4    2020-08-27 [1] CRAN (R 4.0.2)                           
 gdata              2.18.0   2017-06-06 [1] CRAN (R 4.0.2)                           
 gdsfmt             1.24.1   2020-06-16 [1] Bioconductor                             
 generics           0.0.2    2018-11-29 [1] CRAN (R 4.0.2)                           
 GenomeInfoDb       1.24.2   2020-06-15 [1] Bioconductor                             
 GenomeInfoDbData   1.2.3    2020-09-11 [1] Bioconductor                             
 GenomicRanges      1.40.0   2020-04-27 [1] Bioconductor                             
 ggplot2          * 3.3.2    2020-06-19 [1] CRAN (R 4.0.2)                           
 glue               1.4.2    2020-08-27 [1] CRAN (R 4.0.2)                           
 gmodels            2.18.1   2018-06-25 [1] CRAN (R 4.0.2)                           
 gridExtra          2.3      2017-09-09 [1] CRAN (R 4.0.2)                           
 gtable             0.3.0    2019-03-25 [1] CRAN (R 4.0.2)                           
 gtools             3.8.2    2020-03-31 [1] CRAN (R 4.0.2)                           
 GWASExactHW        1.01     2013-01-05 [1] CRAN (R 4.0.2)                           
 hms                0.5.3    2020-01-08 [1] CRAN (R 4.0.2)                           
 htmltools          0.5.0    2020-06-16 [1] CRAN (R 4.0.2)                           
 httpuv             1.5.4    2020-06-06 [1] CRAN (R 4.0.2)                           
 igraph             1.2.5    2020-03-19 [1] CRAN (R 4.0.2)                           
 IRanges            2.22.2   2020-05-21 [1] Bioconductor                             
 KernSmooth         2.23-17  2020-04-26 [4] CRAN (R 4.0.0)                           
 labeling           0.3      2014-08-23 [1] CRAN (R 4.0.2)                           
 later              1.1.0.1  2020-06-05 [1] CRAN (R 4.0.2)                           
 lattice            0.20-41  2020-04-02 [4] CRAN (R 4.0.0)                           
 LearnBayes         2.15.1   2018-03-18 [1] CRAN (R 4.0.2)                           
 lifecycle          0.2.0    2020-03-06 [1] CRAN (R 4.0.2)                           
 logistf            1.23.1   2020-09-04 [1] CRAN (R 4.0.2)                           
 magrittr           1.5      2014-11-22 [1] CRAN (R 4.0.2)                           
 MASS               7.3-53   2020-09-09 [4] CRAN (R 4.0.2)                           
 Matrix             1.2-18   2019-11-27 [4] CRAN (R 4.0.0)                           
 memoise            1.1.0    2017-04-21 [1] CRAN (R 4.0.2)                           
 mgcv               1.8-33   2020-08-27 [4] CRAN (R 4.0.2)                           
 mice               3.11.0   2020-08-05 [1] CRAN (R 4.0.2)                           
 mime               0.9      2020-02-04 [1] CRAN (R 4.0.2)                           
 munsell            0.5.0    2018-06-12 [1] CRAN (R 4.0.2)                           
 nlme               3.1-149  2020-08-23 [4] CRAN (R 4.0.2)                           
 pbmcapply          1.5.0    2019-07-10 [1] CRAN (R 4.0.2)                           
 permute            0.9-5    2019-03-12 [1] CRAN (R 4.0.2)                           
 pillar             1.4.6    2020-07-10 [1] CRAN (R 4.0.2)                           
 pkgbuild           1.1.0    2020-07-13 [1] CRAN (R 4.0.2)                           
 pkgconfig          2.0.3    2019-09-22 [1] CRAN (R 4.0.2)                           
 pkgload            1.1.0    2020-05-29 [1] CRAN (R 4.0.2)                           
 plyr               1.8.6    2020-03-03 [1] CRAN (R 4.0.2)                           
 prettyunits        1.1.1    2020-01-24 [1] CRAN (R 4.0.2)                           
 processx           3.4.4    2020-09-03 [1] CRAN (R 4.0.2)                           
 promises           1.1.1    2020-06-09 [1] CRAN (R 4.0.2)                           
 ps                 1.3.4    2020-08-11 [1] CRAN (R 4.0.2)                           
 purrr              0.3.4    2020-04-17 [1] CRAN (R 4.0.2)                           
 R6                 2.4.1    2019-11-12 [1] CRAN (R 4.0.2)                           
 radiator         * 1.1.7    2020-09-11 [1] Github (thierrygosselin/radiator@ff31083)
 raster             3.3-13   2020-07-17 [1] CRAN (R 4.0.2)                           
 Rcpp               1.0.5    2020-07-06 [1] CRAN (R 4.0.2)                           
 RCurl              1.98-1.2 2020-04-18 [1] CRAN (R 4.0.2)                           
 readr              1.3.1    2018-12-21 [1] CRAN (R 4.0.2)                           
 remotes            2.2.0    2020-07-21 [1] CRAN (R 4.0.2)                           
 reshape2           1.4.4    2020-04-09 [1] CRAN (R 4.0.2)                           
 rlang              0.4.7    2020-07-09 [1] CRAN (R 4.0.2)                           
 rprojroot          1.3-2    2018-01-03 [1] CRAN (R 4.0.2)                           
 rstudioapi         0.11     2020-02-07 [1] CRAN (R 4.0.2)                           
 S4Vectors          0.26.1   2020-05-16 [1] Bioconductor                             
 scales             1.1.1    2020-05-11 [1] CRAN (R 4.0.2)                           
 SeqArray           1.28.1   2020-06-16 [1] Bioconductor                             
 seqinr             3.6-1    2019-09-07 [1] CRAN (R 4.0.2)                           
 SeqVarTools        1.26.0   2020-04-27 [1] Bioconductor                             
 sessioninfo        1.1.1    2018-11-05 [1] CRAN (R 4.0.2)                           
 sf                 0.9-5    2020-07-14 [1] CRAN (R 4.0.2)                           
 shiny              1.5.0    2020-06-23 [1] CRAN (R 4.0.2)                           
 sp                 1.4-2    2020-05-20 [1] CRAN (R 4.0.2)                           
 spData             0.3.8    2020-07-03 [1] CRAN (R 4.0.2)                           
 spdep              1.1-5    2020-06-29 [1] CRAN (R 4.0.2)                           
 stringi            1.5.3    2020-09-09 [1] CRAN (R 4.0.2)                           
 stringr            1.4.0    2019-02-10 [1] CRAN (R 4.0.2)                           
 testthat           2.3.2    2020-03-02 [1] CRAN (R 4.0.2)                           
 tibble             3.0.3    2020-07-10 [1] CRAN (R 4.0.2)                           
 tidyr              1.1.2    2020-08-27 [1] CRAN (R 4.0.2)                           
 tidyselect         1.1.0    2020-05-11 [1] CRAN (R 4.0.2)                           
 units              0.6-7    2020-06-13 [1] CRAN (R 4.0.2)                           
 UpSetR             1.4.0    2019-05-22 [1] CRAN (R 4.0.2)                           
 usethis          * 1.6.1    2020-04-29 [1] CRAN (R 4.0.2)                           
 utf8               1.1.4    2018-05-24 [1] CRAN (R 4.0.2)                           
 vctrs              0.3.4    2020-08-29 [1] CRAN (R 4.0.2)                           
 vegan              2.5-6    2019-09-01 [1] CRAN (R 4.0.2)                           
 withr              2.2.0    2020-04-20 [1] CRAN (R 4.0.2)                           
 xtable             1.8-4    2019-04-21 [1] CRAN (R 4.0.2)                           
 XVector            0.28.0   2020-04-27 [1] Bioconductor                             
 zlibbioc           1.34.0   2020-04-27 [1] Bioconductor

dependencies

Hi, I'm trying to install assigner on a machine running Windows 10 and R 3.3.0. I get an error that I need to update package 'pmbcapply' to version >= 1.3. My understanding is that this package only goes up to 1.0 for Windows. Do you have a work around for this (or am I wrong)? Thanks for any help you can provide.

Error in bind_rows_(x, .id)

Hi there,

I am new to assignment analysis and found your package straight forward and somewhat easy to use. I have a panel of SNP information in genepop format and everytime I run the assignment_ngs() function I get the following error:

assignment12 <- assignment_ngs(tidy12, assignment.analysis = "gsi_sim", sampling.method = "ranked", thl = 0.5, snp.ld = NULL, iteration.subsample = 10, common.markers = FALSE, blacklist.id = NULL, subsample = 5, filename = "12SNP-Panel-run.txt", keep.gsi.files = FALSE, pop.levels = NULL, random.seed = 100, folder = "Vivax12")
#######################################################################
###################### assigner::assignment_ngs #######################
#######################################################################
Assignment analysis with gsi_sim
Folder: /Users/aford29/Downloads/Vivax12/
Scanning for monomorphic markers...
Number of markers before/blacklisted/after: 12/0/12

Tidy genomic data:
Number of markers: 12
Number of chromosome/contig/scaffold: no chromosome info
Number of individuals: 294
Number of populations: 5
Subsampling: selected
Analyzing subsample: 1
Conducting Assignment analysis with ranked markers
Using thl method, ranking Fst with training samples...
Holdout samples saved in your folder
Starting parallel computations for the assignment analysis: ranked markers
For progress: monitor activity in the folder...
| | 0%, ETA NA
Compiling results
Error in bind_rows_(x, .id) : Argument 1 must have names
In addition: Warning messages:
1: In dir.create(file.path(directory)) :
'/Users/aford29/Downloads/Vivax12' already exists
2: In .assigner_parallel(X = iterations.list, FUN = assignment_ranking, :
scheduled cores encountered errors in user code

The warnings at the end just started happening, but the "Error in bind_rows_(x, .id):" has been occurring for every file that I've tried. I've also tried other files and sample files with the same error. If it helps I attached a sample of the file that I am working with

sample_run.txt

I'm not sure if it is the file that is giving me the trouble (maybe formatting errors) but I compared them with others that seemed to work and formatting wise everything seemed pretty much the same. I thought maybe using the strata function would work, but the function individuals2strata didn't work out as I may have to make one from scratch. Sorry if it seems my question/issue is all over the place; I'm pretty new to the field.

Any help you can provide would be much appreciated.

Reading VCF... Error in SeqArray::seqOpen(gds.fn = data.safe$result, readonly = FALSE) : is.character(gds.fn) is not TRUE

Hi,
when using assigner
mf<-radiator::genomic_converter(data="/gpfs/gpfs0/genomdata/Ecogenome/periwinkle/stacks/populations/s1_50%_50%_217ind_fullfiltered.recode.vcf", strata="/gpfs/gpfs0/genomdata/Ecogenome/periwinkle/stacks/populations/s1_pop") %>%dplyr::glimpse()

I get the following error:

################################################################################
######################### radiator::genomic_converter ##########################
################################################################################
Execution date@time: 20230223@1627
Folder created: -277260_radiator_genomic_converter_20230223@1627
Function call and arguments stored in: [email protected]
Filters parameters file generated: [email protected]

Reading VCF...
Error in SeqArray::seqOpen(gds.fn = data.safe$result, readonly = FALSE) :
is.character(gds.fn) is not TRUE

Computation time, overall: 6 sec

Computation time, overall: 14 sec
######################### completed genomic_converter ##########################
✖ Importing data: vcf.file [6.7s]

could you please help me with this?

Error in cbind_all(x)

Hi Thierry,

I'm running assigner to test assignment success between two large groups of samples and I found a weird error message occurring in the marker.number option.

What is the error ?: when I define a marker list > 3 elements (last element corresponding to all markers) it crash.

VCF file detailed
*version 4.2
*from stacks v.1.48
*N individuals = 4066
*N snps = 7151

R Script example

library(assigner)

message("perform assignment...")
#Two Regions - north & south
assign1 <- assigner::assignment_ngs(
  data = "batch_3_p70_x9_H0.6_y9_no_singletons_4066indv.vcf",
  marker.number = c(100, 500, 1000, 2500, 6000, "all"),
  sampling.method = "ranked",
  thl = 0.5, iteration.method = 10,
  assignment.analysis = "gsi_sim",
  subsample = 1000,
  iteration.subsample=5,
  strata = "strata_NS.txt",
  parallel.core = 5,
  #common.markers = FALSE,
  #snp.ld=FALSE,
  folder = "THL_0.5_iteration_10_regions-sampling_NOR_SOU_test")

Shell error:
radiator is working on file ...
VCF is biallelic
updating markers metadata and stats
[====...] 100%
Error in cbind_all(x) : Argument 3 must be length 7151, not 63

So 7151 correspond to the nSNPs number however I don't understand the 63

Bioinformatic resources:
Unix server calcul (SLURM)
CPU allowed from 2 to 8 (same error)
RAM allowed 20G
R v.3.5.1

Something weird is that when I fix the marker.number to only 3 element as c(100,1000,7151) it works...

Do you have an idea about this ? I think that the pb is located in radiator vcf importation.

Best,
Yann.

error running assignR on converted genepop file

Dear Thierry et al.,

I am getting this error when I run assignR:

Calibrating REF/ALT alleles... Error in if (detect.gt == "GT_VCF_NUC") { : argument is of length zero
when I try to run assignR on a converted genepop file.

Here is my code to load and convert to tidy format:

> packageVersion("assignR") [1] ‘2.0.0’

> packageVersion("radiator") [1] ‘1.1.9’

BC.tidy <- radiator::tidy_genepop(data = "SNP.BC_3.11.21.hwe.bi.recode.gen")

BC.tidy
# A tibble: 2,760,186 x 4
POP_ID INDIVIDUALS MARKERS GT
<fct> <chr> <fct> <chr>
1 1 CED-02 HiC_scaffold_1__9318304_1006119 001001
2 1 CED-03 HiC_scaffold_1__9318304_1006119 001001
3 1 CED-04 HiC_scaffold_1__9318304_1006119 001002
4 1 CED-05 HiC_scaffold_1__9318304_1006119 001001
5 1 CED-06 HiC_scaffold_1__9318304_1006119 001002
6 1 CED-07 HiC_scaffold_1__9318304_1006119 001001
7 1 CED-08 HiC_scaffold_1__9318304_1006119 001002
8 1 CED-08dup HiC_scaffold_1__9318304_1006119 001002
9 1 CED-09 HiC_scaffold_1__9318304_1006119 000000
10 1 CED-10 HiC_scaffold_1__9318304_1006119 002002
… with 2,760,176 more rows

This genpop file was converted from a dDocent-created (free-bayes) VCF file and it loaded fine in genepop or GenoDive etc. has 429 individuals; 6,434 loci; 12,868 alleles;

Then the assignR code:

> test3 <- assigner::assignment_ngs(data = BC.tidy, assignment.analysis = "gsi_sim", marker.number = c(100, 200, "all"), markers.sampling = "ranked", thl = 0.3)

################################################################################
########################## assigner::assignment_ngs ############################
################################################################################
Execution date/time: 20210321@1157
Assignment analysis with gsi_sim
Calibrating REF/ALT alleles...
Error in if (detect.gt == "GT_VCF_NUC") { : argument is of length zero

**Computation time, overall: 2 sec
########################## assignment_ngs completed ############################

Clearly there is a format error with the BC.tidy dataset, but im not sure where Ive gone wrong here. I am sorry if I am missing something obvious, but my understanding was that I could use radiator to convert to a tidy genotype format, and then run assignR on the converted file (the tibble BC.tidy)

UPDATE:
I get the same error on the example dataset from the assignR package (from the tutorial

> data <- data_assigner_sim_01
> test1 <- assigner::assignment_ngs( data = data, assignment.analysis = "gsi_sim", markers.sampling = "ranked", thl = 0.2, iteration.method = 5)
################################################################################
########################## assigner::assignment_ngs ############################
################################################################################
Execution date/time: 20210321@1655
Assignment analysis with gsi_sim
Calibrating REF/ALT alleles...
Error in if (detect.gt == "GT_VCF_NUC") { : argument is of length zero

Computation time, overall: 0 sec
########################## assignment_ngs completed ############################
`

UPDATE- I am able to recreate this same error with the example dataset from the 'getting started' tutorial [here])(http://thierrygosselin.github.io/assigner/articles/get_started.html)

> data <- data_assigner_sim_01
> test1 <- assigner::assignment_ngs( data = data, assignment.analysis = "gsi_sim", markers.sampling = "ranked", thl = 0.2, iteration.method = 5)

################################################################################
########################## assigner::assignment_ngs ############################
################################################################################
Execution date/time: 20210321@1655
Assignment analysis with gsi_sim
Calibrating REF/ALT alleles...
Error in if (detect.gt == "GT_VCF_NUC") { : argument is of length zero

Computation time, overall: 0 sec
########################## assignment_ngs completed ############################

Thanks for any help here!

LP

assigner::assignment_ngs() - Error in dplyr::bind_rows(.) : Argument 1 must have names.

Dear Thierry,

Description of the bug
assigner::assignment_ngs does not work with the dataset data_assigner_sim_01 included in assigner - suspecting it is a dplyr issue. I tried dplyr v1.0.0 and the latest v1.0.10 without sucess.
I used the dataset included in assigner after having problems with my own dataset. I wanted to know if it was a problem with the formatting of my data (also dplyr related issue) or if it was the function.

To reproduce

library(assigner)
data<- data_assigner_sim_01
test1 <- assigner::assignment_ngs(
  data = data,
  assignment.analysis = "gsi_sim",
  markers.sampling = "ranked", 
 thl = 0.2,
 iteration.method = 5
)

error message

################################################################################
########################## assigner::assignment_ngs ############################
################################################################################
Execution date/time: 20221206@1917
Assignment analysis with gsi_sim
Subsampling: not selected
Conducting Assignment analysis using Training, Holdout, Leave-one-out
Using training samples to rank markers based on Fst
Holdout samples saved in your folder
Starting parallel computations, for progress monitor activity in folder...
Ranking markers based on Fst
Removing holdout individuals
Fst computation...
Error in dplyr::bind_rows(.) : Argument 1 must have names.

Computation time, overall: 6 sec
########################## assignment_ngs completed ############################

  • output of devtools::session_info()
Session info ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 setting  value
 version  R version 4.2.1 (2022-06-23 ucrt)
 os       Windows Server 2012 R2 x64 (build 9600)
 system   x86_64, mingw32
 ui       Rgui
 language (EN)
 collate  English_United States.1252
 ctype    English_United States.1252
 tz       unknown
 date     2022-12-06
 pandoc   NA

- Packages -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 package     * version  date (UTC) lib source
 ade4          1.7-20   2022-11-01 [1] CRAN (R 4.2.2)
 adegenet      2.1.8    2022-10-02 [1] CRAN (R 4.2.2)
 ape           5.6-2    2022-03-02 [1] CRAN (R 4.2.1)
 assertthat    0.2.1    2019-03-21 [1] CRAN (R 4.2.1)
 assigner    * 0.5.8    2022-09-15 [1] Github (thierrygosselin/assigner@d39a692)
 bit           4.0.4    2020-08-04 [1] CRAN (R 4.2.1)
 bit64         4.0.5    2020-08-30 [1] CRAN (R 4.2.1)
 cachem        1.0.6    2021-08-19 [1] CRAN (R 4.2.1)
 callr         3.7.3    2022-11-02 [1] CRAN (R 4.2.2)
 carrier       0.1.0    2018-10-16 [1] CRAN (R 4.2.1)
 cli           3.4.1    2022-09-23 [1] CRAN (R 4.2.2)
 cluster       2.1.4    2022-08-22 [1] CRAN (R 4.2.1)
 codetools     0.2-18   2020-11-04 [2] CRAN (R 4.2.1)
 colorspace    2.0-3    2022-02-21 [1] CRAN (R 4.2.1)
 crayon        1.5.2    2022-09-29 [1] CRAN (R 4.2.2)
 curl          4.3.3    2022-10-06 [1] CRAN (R 4.2.2)
 data.table    1.14.4   2022-10-17 [1] CRAN (R 4.2.2)
 DBI           1.1.3    2022-06-18 [1] CRAN (R 4.2.1)
 devtools      2.4.5    2022-10-11 [1] CRAN (R 4.2.2)
 digest        0.6.30   2022-10-18 [1] CRAN (R 4.2.2)
 dplyr       * 1.0.10   2022-09-01 [1] CRAN (R 4.2.2)
 ellipsis      0.3.2    2021-04-29 [1] CRAN (R 4.2.1)
 fansi         1.0.3    2022-03-24 [1] CRAN (R 4.2.1)
 fastmap       1.1.0    2021-01-25 [1] CRAN (R 4.2.1)
 fs            1.5.2    2021-12-08 [1] CRAN (R 4.2.1)
 furrr         0.3.1    2022-08-15 [1] CRAN (R 4.2.1)
 future        1.29.0   2022-11-06 [1] CRAN (R 4.2.2)
 generics      0.1.3    2022-07-05 [1] CRAN (R 4.2.1)
 ggplot2       3.4.0    2022-11-04 [1] CRAN (R 4.2.2)
 globals       0.16.2   2022-11-21 [1] CRAN (R 4.2.2)
 glue          1.6.2    2022-02-24 [1] CRAN (R 4.2.1)
 gtable        0.3.1    2022-09-01 [1] CRAN (R 4.2.1)
 hms           1.1.2    2022-08-19 [1] CRAN (R 4.2.1)
 htmltools     0.5.3    2022-07-18 [1] CRAN (R 4.2.1)
 htmlwidgets   1.5.4    2021-09-08 [1] CRAN (R 4.2.1)
 httpuv        1.6.6    2022-09-08 [1] CRAN (R 4.2.1)
 igraph        1.3.5    2022-09-22 [1] CRAN (R 4.2.2)
 later         1.3.0    2021-08-18 [1] CRAN (R 4.2.1)
 lattice       0.20-45  2021-09-22 [2] CRAN (R 4.2.1)
 lifecycle     1.0.3    2022-10-07 [1] CRAN (R 4.2.2)
 listenv       0.8.0    2019-12-05 [1] CRAN (R 4.2.1)
 magrittr      2.0.3    2022-03-30 [1] CRAN (R 4.2.1)
 MASS          7.3-58.1 2022-08-03 [1] CRAN (R 4.2.1)
 Matrix        1.5-3    2022-11-11 [1] CRAN (R 4.2.2)
 memoise       2.0.1    2021-11-26 [1] CRAN (R 4.2.1)
 mgcv          1.8-40   2022-03-29 [2] CRAN (R 4.2.1)
 mime          0.12     2021-09-28 [1] CRAN (R 4.2.0)
 miniUI        0.1.1.1  2018-05-18 [1] CRAN (R 4.2.1)
 munsell       0.5.0    2018-06-12 [1] CRAN (R 4.2.1)
 nlme          3.1-160  2022-10-10 [1] CRAN (R 4.2.2)
 parallelly    1.32.1   2022-07-21 [1] CRAN (R 4.2.1)
 permute       0.9-7    2022-01-27 [1] CRAN (R 4.2.1)
 pillar        1.8.1    2022-08-19 [1] CRAN (R 4.2.1)
 pkgbuild      1.4.0    2022-11-27 [1] CRAN (R 4.2.2)
 pkgconfig     2.0.3    2019-09-22 [1] CRAN (R 4.2.1)
 pkgload       1.3.2    2022-11-16 [1] CRAN (R 4.2.2)
 plyr          1.8.8    2022-11-11 [1] CRAN (R 4.2.2)
 prettyunits   1.1.1    2020-01-24 [1] CRAN (R 4.2.1)
 processx      3.8.0    2022-10-26 [1] CRAN (R 4.2.2)
 profvis       0.3.7    2020-11-02 [1] CRAN (R 4.2.1)
 promises      1.2.0.1  2021-02-11 [1] CRAN (R 4.2.1)
 ps            1.7.2    2022-10-26 [1] CRAN (R 4.2.2)
 purrr         0.3.5    2022-10-06 [1] CRAN (R 4.2.2)
 R6            2.5.1    2021-08-19 [1] CRAN (R 4.2.1)
 radiator      1.2.4    2022-11-15 [1] Github (thierrygosselin/radiator@06ae13f)
 Rcpp          1.0.9    2022-07-08 [1] CRAN (R 4.2.1)
 readr         2.1.3    2022-10-01 [1] CRAN (R 4.2.2)
 remotes       2.4.2    2021-11-30 [1] CRAN (R 4.2.1)
 reshape2      1.4.4    2020-04-09 [1] CRAN (R 4.2.1)
 rlang         1.0.6    2022-09-24 [1] CRAN (R 4.2.2)
 scales        1.2.1    2022-08-20 [1] CRAN (R 4.2.1)
 seqinr        4.2-16   2022-05-19 [1] CRAN (R 4.2.1)
 sessioninfo   1.2.2    2021-12-06 [1] CRAN (R 4.2.1)
 shiny         1.7.3    2022-10-25 [1] CRAN (R 4.2.2)
 stringi       1.7.8    2022-07-11 [1] CRAN (R 4.2.1)
 stringr     * 1.5.0    2022-12-02 [1] CRAN (R 4.2.2)
 tibble        3.1.8    2022-07-22 [1] CRAN (R 4.2.1)
 tidyr         1.2.1    2022-09-08 [1] CRAN (R 4.2.1)
 tidyselect    1.2.0    2022-10-10 [1] CRAN (R 4.2.2)
 tzdb          0.3.0    2022-03-28 [1] CRAN (R 4.2.1)
 urlchecker    1.0.1    2021-11-30 [1] CRAN (R 4.2.1)
 usethis       2.1.6    2022-05-25 [1] CRAN (R 4.2.1)
 utf8          1.2.2    2021-07-24 [1] CRAN (R 4.2.1)
 vctrs         0.5.0    2022-10-22 [1] CRAN (R 4.2.2)
 vegan         2.6-4    2022-10-11 [1] CRAN (R 4.2.2)
 vroom         1.6.0    2022-09-30 [1] CRAN (R 4.2.2)
 withr         2.5.0    2022-03-03 [1] CRAN (R 4.2.1)
 xtable        1.8-4    2019-04-21 [1] CRAN (R 4.2.1)

 [1] C:/Users/Admin/AppData/Local/R/win-library/4.2
 [2] C:/Program Files/R/R-4.2.1/library

---------------------------------------------------------------------------------

Thank you for the help

Have a good day

Sandrine

Error while using the subsampling option in Fst_WC84()

Hi, I am interested in using the Fst_WC84() with subsampling. However, while getting familiar with your function by using datasets provided by you, I am running into the following error :

**library(assigner)
data <- data_assigner_sim_01
assigner::fst_WC84(data, filename = "Test", subsample = 36, iteration.subsample = 20)

Error: Argument 1 must have names

  1. stop(structure(list(message = "Argument 1 must have names", call = NULL,
    cppstack = NULL), class = c("Rcpp::exception", "C++Error",
    "error", "condition")))
  2. bind_rows_(x, .id)
  3. dplyr::bind_rows(res$pairwise.fst.subsample)
  4. eval(lhs, parent, parent)
  5. eval(lhs, parent, parent)
  6. dplyr::bind_rows(res$pairwise.fst.subsample) %>% dplyr::group_by(POP1,
    POP2) %>% dplyr::summarise_all(.tbl = ., .funs = mean, na.rm = TRUE) %>%
    dplyr::mutate(ITERATIONS = rep(iteration.subsample, n())) at fst_WC84.R#649
  7. assigner::fst_WC84(data, filename = "Test", subsample = 36, iteration.subsample = 20 )_**

I have read other reports about a similar issue, but that is all in the context of assignment analysis and not Fst calculations. Is this a bug or am I missing something here?

Thank you,

P.S. The function runs just fine without the subsampling argument.

digits in heatmap_fst()

Nothing happens when I'm trying to change argument 'digits' in heatmap_fst(), it is always 5 decimal digits on heatmap. For instance:

heatmap_fst(fst.ci$pairwise.fst.full.matrix, fst.ci$pairwise.fst.ci.matrix, n.s = TRUE,
digits = 3, color.low = "white", color.mid = "grey",
color.high = "black", text.size = 4, plot.size = 40,
pop.levels = NULL, path.folder = NULL, filename = NULL)

heatmap_fst(fst.ci$pairwise.fst.full.matrix, fst.ci$pairwise.fst.ci.matrix, n.s = TRUE,
digits = 5, color.low = "white", color.mid = "grey",
color.high = "black", text.size = 4, plot.size = 40,
pop.levels = NULL, path.folder = NULL, filename = NULL)

heatmap_fst(fst.ci$pairwise.fst.full.matrix, fst.ci$pairwise.fst.ci.matrix, n.s = TRUE,
digits = 8, color.low = "white", color.mid = "grey",
color.high = "black", text.size = 4, plot.size = 40,
pop.levels = NULL, path.folder = NULL, filename = NULL)

all three give me identical results.

There is another problem, probably related to the described above - the fst values and corresponding CI intervals are mixed between upper and lower parts of matrix on the heatmap:

Warning messages:
1: Column POP1 has different attributes on LHS and RHS of join
2: Column POP2 has different attributes on LHS and RHS of join

plot

devtools::session_info()
─ Session info
setting value
version R version 3.6.2 (2019-12-12)
os Ubuntu 18.04.3 LTS
system x86_64, linux-gnu
ui RStudio
language (EN)
collate en_US.UTF-8
ctype en_US.UTF-8
tz Asia/Yekaterinburg
date 2020-01-07

─ Packages
package * version date lib source
ade4 * 1.7-13 2018-08-31 [1] CRAN (R 3.6.1)
adegenet * 2.1.1 2018-02-02 [1] CRAN (R 3.6.1)
ape 5.3 2019-03-17 [1] CRAN (R 3.6.1)
assertthat 0.2.1 2019-03-21 [1] CRAN (R 3.6.1)
assigner * 0.5.6 2019-12-08 [1] Github (b941111)
backports 1.1.5 2019-10-02 [1] CRAN (R 3.6.1)
Biobase 2.44.0 2019-05-02 [1] Bioconductor
BiocGenerics 0.30.0 2019-05-02 [1] Bioconductor
Biostrings 2.52.0 2019-05-02 [1] Bioconductor
bitops 1.0-6 2013-08-17 [1] CRAN (R 3.6.1)
boot 1.3-24 2019-12-20 [4] CRAN (R 3.6.2)
broom 0.5.2 2019-04-07 [1] CRAN (R 3.6.1)
callr 3.3.2 2019-09-22 [1] CRAN (R 3.6.1)
class 7.3-15 2019-01-01 [4] CRAN (R 3.6.1)
classInt 0.4-2 2019-10-17 [1] CRAN (R 3.6.1)
cli 1.1.0 2019-03-19 [1] CRAN (R 3.6.1)
cluster 2.1.0 2019-06-19 [4] CRAN (R 3.6.1)
coda 0.19-3 2019-07-05 [1] CRAN (R 3.6.1)
colorspace 1.4-1 2019-03-18 [1] CRAN (R 3.6.1)
crayon 1.3.4 2017-09-16 [1] CRAN (R 3.6.1)
data.table 1.12.6 2019-10-18 [1] CRAN (R 3.6.1)
DBI 1.0.0 2018-05-02 [1] CRAN (R 3.6.1)
deldir 0.1-23 2019-07-31 [1] CRAN (R 3.6.1)
desc 1.2.0 2018-05-01 [1] CRAN (R 3.6.1)
devtools 2.1.0 2019-07-06 [1] CRAN (R 3.6.1)
digest 0.6.23 2019-11-23 [1] CRAN (R 3.6.1)
dplyr 0.8.3 2019-07-04 [1] CRAN (R 3.6.1)
e1071 1.7-3 2019-11-26 [1] CRAN (R 3.6.1)
ellipsis 0.3.0 2019-09-20 [1] CRAN (R 3.6.1)
expm 0.999-4 2019-03-21 [1] CRAN (R 3.6.1)
fansi 0.4.0 2018-10-05 [1] CRAN (R 3.6.1)
farver 2.0.1 2019-11-13 [1] CRAN (R 3.6.1)
fastmap 1.0.1 2019-10-08 [1] CRAN (R 3.6.1)
fs 1.3.1 2019-05-06 [1] CRAN (R 3.6.1)
fst 0.9.0 2019-04-09 [1] CRAN (R 3.6.1)
gdata 2.18.0 2017-06-06 [1] CRAN (R 3.6.1)
gdsfmt 1.20.0 2019-05-02 [1] Bioconductor
generics 0.0.2 2018-11-29 [1] CRAN (R 3.6.1)
GenomeInfoDb 1.20.0 2019-05-02 [1] Bioconductor
GenomeInfoDbData 1.2.1 2019-12-08 [1] Bioconductor
GenomicRanges 1.36.1 2019-09-06 [1] Bioconductor
ggplot2 3.2.1 2019-08-10 [1] CRAN (R 3.6.1)
glue 1.3.1 2019-03-12 [1] CRAN (R 3.6.1)
gmodels 2.18.1 2018-06-25 [1] CRAN (R 3.6.1)
gridExtra 2.3 2017-09-09 [1] CRAN (R 3.6.1)
gtable 0.3.0 2019-03-25 [1] CRAN (R 3.6.1)
gtools 3.8.1 2018-06-26 [1] CRAN (R 3.6.1)
GWASExactHW 1.01 2013-01-05 [1] CRAN (R 3.6.1)
hms 0.5.2 2019-10-30 [1] CRAN (R 3.6.1)
htmltools 0.4.0 2019-10-04 [1] CRAN (R 3.6.1)
httpuv 1.5.2 2019-09-11 [1] CRAN (R 3.6.1)
igraph 1.2.4.2 2019-11-27 [1] CRAN (R 3.6.1)
IRanges 2.18.3 2019-09-24 [1] Bioconductor
jomo 2.6-10 2019-10-22 [1] CRAN (R 3.6.1)
KernSmooth 2.23-16 2019-10-15 [4] CRAN (R 3.6.1)
labeling 0.3 2014-08-23 [1] CRAN (R 3.6.1)
later 1.0.0 2019-10-04 [1] CRAN (R 3.6.1)
lattice 0.20-38 2018-11-04 [4] CRAN (R 3.6.1)
lazyeval 0.2.2 2019-03-15 [1] CRAN (R 3.6.1)
LearnBayes 2.15.1 2018-03-18 [1] CRAN (R 3.6.1)
lifecycle 0.1.0 2019-08-01 [1] CRAN (R 3.6.1)
lme4 1.1-21 2019-03-05 [1] CRAN (R 3.6.1)
logistf 1.23 2018-07-19 [1] CRAN (R 3.6.1)
magrittr 1.5 2014-11-22 [1] CRAN (R 3.6.1)
MASS 7.3-51.5 2019-12-20 [4] CRAN (R 3.6.2)
Matrix 1.2-18 2019-11-27 [4] CRAN (R 3.6.1)
memoise 1.1.0 2017-04-21 [1] CRAN (R 3.6.1)
mgcv 1.8-31 2019-11-09 [4] CRAN (R 3.6.1)
mice 3.6.0 2019-07-10 [1] CRAN (R 3.6.1)
mime 0.7 2019-06-11 [1] CRAN (R 3.6.1)
minqa 1.2.4 2014-10-09 [1] CRAN (R 3.6.1)
mitml 0.3-7 2019-01-07 [1] CRAN (R 3.6.1)
munsell 0.5.0 2018-06-12 [1] CRAN (R 3.6.1)
nlme 3.1-143 2019-12-10 [4] CRAN (R 3.6.2)
nloptr 1.2.1 2018-10-03 [1] CRAN (R 3.6.1)
nnet 7.3-12 2016-02-02 [4] CRAN (R 3.6.1)
pan 1.6 2018-06-29 [1] CRAN (R 3.6.1)
pbmcapply 1.5.0 2019-07-10 [1] CRAN (R 3.6.1)
permute 0.9-5 2019-03-12 [1] CRAN (R 3.6.1)
pillar 1.4.2 2019-06-29 [1] CRAN (R 3.6.1)
pinfsc50 1.1.0 2016-12-02 [1] CRAN (R 3.6.1)
pkgbuild 1.0.5 2019-08-26 [1] CRAN (R 3.6.1)
pkgconfig 2.0.3 2019-09-22 [1] CRAN (R 3.6.1)
pkgload 1.0.2 2018-10-29 [1] CRAN (R 3.6.1)
plyr 1.8.4 2016-06-08 [1] CRAN (R 3.6.1)
prettyunits 1.0.2 2015-07-13 [1] CRAN (R 3.6.1)
processx 3.4.1 2019-07-18 [1] CRAN (R 3.6.1)
promises 1.1.0 2019-10-04 [1] CRAN (R 3.6.1)
ps 1.3.0 2018-12-21 [1] CRAN (R 3.6.1)
purrr 0.3.3 2019-10-18 [1] CRAN (R 3.6.1)
R6 2.4.1 2019-11-12 [1] CRAN (R 3.6.1)
radiator * 1.1.2 2019-12-08 [1] Github (thierrygosselin/radiator@480ef0f)
Rcpp 1.0.3 2019-11-08 [1] CRAN (R 3.6.1)
RCurl 1.95-4.12 2019-03-04 [1] CRAN (R 3.6.1)
readr 1.3.1 2018-12-21 [1] CRAN (R 3.6.1)
remotes 2.1.0 2019-06-24 [1] CRAN (R 3.6.1)
reshape2 1.4.3 2017-12-11 [1] CRAN (R 3.6.1)
rlang 0.4.2 2019-11-23 [1] CRAN (R 3.6.1)
rpart 4.1-15 2019-04-12 [4] CRAN (R 3.6.1)
rprojroot 1.3-2 2018-01-03 [1] CRAN (R 3.6.1)
rstudioapi 0.10 2019-03-19 [1] CRAN (R 3.6.1)
S4Vectors 0.22.1 2019-09-09 [1] Bioconductor
scales 1.1.0 2019-11-18 [1] CRAN (R 3.6.1)
SeqArray 1.24.2 2019-07-12 [1] Bioconductor
seqinr 3.6-1 2019-09-07 [1] CRAN (R 3.6.1)
SeqVarTools 1.22.0 2019-05-02 [1] Bioconductor
sessioninfo 1.1.1 2018-11-05 [1] CRAN (R 3.6.1)
sf 0.8-0 2019-09-17 [1] CRAN (R 3.6.1)
shiny 1.4.0 2019-10-10 [1] CRAN (R 3.6.1)
sp 1.3-2 2019-11-07 [1] CRAN (R 3.6.1)
spData 0.3.2 2019-09-19 [1] CRAN (R 3.6.1)
spdep 1.1-3 2019-09-18 [1] CRAN (R 3.6.1)
stringi 1.4.3 2019-03-12 [1] CRAN (R 3.6.1)
stringr 1.4.0 2019-02-10 [1] CRAN (R 3.6.1)
survival 3.1-8 2019-12-03 [4] CRAN (R 3.6.2)
testthat 2.2.1 2019-07-25 [1] CRAN (R 3.6.1)
tibble 2.1.3 2019-06-06 [1] CRAN (R 3.6.1)
tidyr 1.0.0 2019-09-11 [1] CRAN (R 3.6.1)
tidyselect 0.2.5 2018-10-11 [1] CRAN (R 3.6.1)
units 0.6-5 2019-10-08 [1] CRAN (R 3.6.1)
UpSetR 1.4.0 2019-05-22 [1] CRAN (R 3.6.1)
usethis 1.5.1 2019-07-04 [1] CRAN (R 3.6.1)
utf8 1.1.4 2018-05-24 [1] CRAN (R 3.6.1)
vcfR * 1.8.0 2018-04-17 [1] CRAN (R 3.6.1)
vctrs 0.2.0 2019-07-05 [1] CRAN (R 3.6.1)
vegan 2.5-6 2019-09-01 [1] CRAN (R 3.6.1)
viridisLite 0.3.0 2018-02-01 [1] CRAN (R 3.6.1)
withr 2.1.2 2018-03-15 [1] CRAN (R 3.6.1)
xtable 1.8-4 2019-04-21 [1] CRAN (R 3.6.1)
XVector 0.24.0 2019-05-02 [1] Bioconductor
zeallot 0.1.0 2018-01-28 [1] CRAN (R 3.6.1)
zlibbioc 1.30.0 2019-05-02 [1] Bioconductor

assignment_ngs error: problem with 'mutate()'

I cannot help you if I cannot reproduce the problem.
Consequently, when reporting an issue, make sure to include:

Describe the bug
assigner::assignment_ngs does not work- suspecting it is a dplyr issue. I tried dplyr v1.0.0 and the latest v1.0.4

To Reproduce
Include the steps to reproduce the behavior:

  • the exact command (function, arguments, values) used
    Command I ran:
assigner::assignment_ngs(
  GENLIGHT391ind_3_realpop$genlight,
  assignment.analysis = "gsi_sim",
  markers.sampling = "ranked", 
  thl = 0.5,
  iteration.method = 30,
  adegenet.dapc.opt = "optim.a.score",
  marker.number = c(2, 4, 8, 16, 32, 64, 128, 200, 500, 1000, 2000, "all"),
  subsample = "min", 
  iteration.subsample = 3
)
  • the complete error message you're getting
Error: Problem with `mutate()` input `..1`.
x Can't subset columns that don't exist.
x Column `STRATA` doesn't exist.
ℹ Input `..1` is `(function (.cols = everything(), .fns = NULL, ..., .names = NULL) ...`.
Run `rlang::last_error()` to see where the error occurred.

Computation time, overall: 7 sec
  • the output of devtools::session_info()
    Strangely I have macOS11.2.2, but in the below session info it says 10.16?
─ Session info ─────────────────────────────────────────────────────────────────────────────────────────────────
 setting  value                       
 version  R version 4.0.2 (2020-06-22)
 os       macOS  10.16                
 system   x86_64, darwin17.0          
 ui       RStudio                     
 language (EN)                        
 collate  en_CA.UTF-8                 
 ctype    en_CA.UTF-8                 
 tz       America/Toronto             
 date     2021-03-02                  

─ Packages ─────────────────────────────────────────────────────────────────────────────────────────────────────
 package         * version  date       lib source                                   
 abind             1.4-5    2016-07-21 [1] CRAN (R 4.0.2)                           
 ade4            * 1.7-16   2020-10-28 [1] CRAN (R 4.0.2)                           
 adegenet        * 2.1.3    2020-05-10 [1] CRAN (R 4.0.2)                           
 adegraphics       1.0-15   2018-12-18 [1] CRAN (R 4.0.2)                           
 adephylo          1.1-11   2017-12-18 [1] CRAN (R 4.0.2)                           
 adespatial        0.3-10   2021-02-09 [1] CRAN (R 4.0.2)                           
 ape               5.4-1    2020-08-13 [1] CRAN (R 4.0.2)                           
 assertthat        0.2.1    2019-03-21 [1] CRAN (R 4.0.2)                           
 assigner        * 0.5.8    2021-02-26 [1] Github (thierrygosselin/assigner@d39a692)
 backports         1.2.1    2020-12-09 [1] CRAN (R 4.0.2)                           
 boot              1.3-25   2020-04-26 [1] CRAN (R 4.0.2)                           
 broom             0.7.3    2020-12-16 [1] CRAN (R 4.0.2)                           
 callr             3.5.1    2020-10-13 [1] CRAN (R 4.0.2)                           
 car               3.0-10   2020-09-29 [1] CRAN (R 4.0.2)                           
 carData           3.0-4    2020-05-22 [1] CRAN (R 4.0.2)                           
 cellranger        1.1.0    2016-07-27 [1] CRAN (R 4.0.2)                           
 class             7.3-17   2020-04-26 [1] CRAN (R 4.0.2)                           
 classInt          0.4-3    2020-04-07 [1] CRAN (R 4.0.2)                           
 cli               2.2.0    2020-11-20 [1] CRAN (R 4.0.2)                           
 cluster           2.1.0    2019-06-19 [1] CRAN (R 4.0.2)                           
 coda              0.19-4   2020-09-30 [1] CRAN (R 4.0.2)                           
 codetools         0.2-18   2020-11-04 [1] CRAN (R 4.0.2)                           
 colorspace        2.0-0    2020-11-11 [1] CRAN (R 4.0.2)                           
 cowplot           1.0.0    2019-07-11 [1] CRAN (R 4.0.2)                           
 crayon            1.3.4    2017-09-16 [1] CRAN (R 4.0.2)                           
 curl              4.3      2019-12-02 [1] CRAN (R 4.0.1)                           
 data.table        1.12.8   2019-12-09 [1] CRAN (R 4.0.1)                           
 data.tree         1.0.0    2020-08-03 [1] CRAN (R 4.0.2)                           
 DBI               1.1.0    2019-12-15 [1] CRAN (R 4.0.2)                           
 deldir            0.2-9    2021-01-16 [1] CRAN (R 4.0.2)                           
 desc              1.2.0    2018-05-01 [1] CRAN (R 4.0.2)                           
 devtools        * 2.3.2    2020-09-18 [1] CRAN (R 4.0.2)                           
 DiagrammeR        1.0.6.1  2020-05-08 [1] CRAN (R 4.0.2)                           
 digest            0.6.27   2020-10-24 [1] CRAN (R 4.0.2)                           
 dplyr           * 1.0.0    2020-05-29 [1] CRAN (R 4.0.2)                           
 e1071             1.7-3    2019-11-26 [1] CRAN (R 4.0.2)                           
 ellipsis          0.3.1    2020-05-15 [1] CRAN (R 4.0.2)                           
 expm              0.999-5  2020-07-20 [1] CRAN (R 4.0.2)                           
 fansi             0.4.1    2020-01-08 [1] CRAN (R 4.0.2)                           
 fastmap           1.0.1    2019-10-08 [1] CRAN (R 4.0.2)                           
 forcats           0.5.0    2020-03-01 [1] CRAN (R 4.0.2)                           
 foreign           0.8-80   2020-05-24 [1] CRAN (R 4.0.2)                           
 fs                1.4.2    2020-06-30 [1] CRAN (R 4.0.2)                           
 gdata             2.18.0   2017-06-06 [1] CRAN (R 4.0.2)                           
 generics          0.0.2    2018-11-29 [1] CRAN (R 4.0.2)                           
 ggplot2         * 3.3.2    2020-06-19 [1] CRAN (R 4.0.2)                           
 ggpubr            0.4.0    2020-06-27 [1] CRAN (R 4.0.2)                           
 ggsignif          0.6.0    2019-08-08 [1] CRAN (R 4.0.2)                           
 glue              1.4.1    2020-05-13 [1] CRAN (R 4.0.2)                           
 gmodels           2.18.1   2018-06-25 [1] CRAN (R 4.0.2)                           
 grur            * 0.1.4    2021-02-26 [1] Github (thierrygosselin/grur@d31c423)    
 gtable            0.3.0    2019-03-25 [1] CRAN (R 4.0.2)                           
 gtools            3.8.2    2020-03-31 [1] CRAN (R 4.0.2)                           
 haven             2.3.1    2020-06-01 [1] CRAN (R 4.0.2)                           
 hms               0.5.3    2020-01-08 [1] CRAN (R 4.0.2)                           
 htmltools         0.5.1.1  2021-01-22 [1] CRAN (R 4.0.2)                           
 htmlwidgets       1.5.1    2019-10-08 [1] CRAN (R 4.0.2)                           
 httpuv            1.5.4    2020-06-06 [1] CRAN (R 4.0.2)                           
 httr              1.4.2    2020-07-20 [1] CRAN (R 4.0.2)                           
 igraph            1.2.5    2020-03-19 [1] CRAN (R 4.0.2)                           
 jpeg              0.1-8.1  2019-10-24 [1] CRAN (R 4.0.2)                           
 jsonlite          1.7.2    2020-12-09 [1] CRAN (R 4.0.2)                           
 KernSmooth        2.23-17  2020-04-26 [1] CRAN (R 4.0.2)                           
 later             1.1.0.1  2020-06-05 [1] CRAN (R 4.0.2)                           
 lattice           0.20-41  2020-04-02 [1] CRAN (R 4.0.2)                           
 latticeExtra      0.6-29   2019-12-19 [1] CRAN (R 4.0.2)                           
 lazyeval          0.2.2    2019-03-15 [1] CRAN (R 4.0.2)                           
 LearnBayes        2.15.1   2018-03-18 [1] CRAN (R 4.0.2)                           
 lifecycle         0.2.0    2020-03-06 [1] CRAN (R 4.0.2)                           
 magrittr          1.5      2014-11-22 [1] CRAN (R 4.0.2)                           
 MASS              7.3-51.6 2020-04-26 [1] CRAN (R 4.0.2)                           
 Matrix            1.2-18   2019-11-27 [1] CRAN (R 4.0.2)                           
 memoise           1.1.0    2017-04-21 [1] CRAN (R 4.0.2)                           
 mgcv              1.8-31   2019-11-09 [1] CRAN (R 4.0.2)                           
 mime              0.9      2020-02-04 [1] CRAN (R 4.0.2)                           
 munsell           0.5.0    2018-06-12 [1] CRAN (R 4.0.2)                           
 nlme              3.1-148  2020-05-24 [1] CRAN (R 4.0.2)                           
 openxlsx          4.1.5    2020-05-06 [1] CRAN (R 4.0.2)                           
 permute           0.9-5    2019-03-12 [1] CRAN (R 4.0.2)                           
 phylobase         0.8.10   2020-03-01 [1] CRAN (R 4.0.2)                           
 pillar            1.4.6    2020-07-10 [1] CRAN (R 4.0.2)                           
 pinfsc50          1.2.0    2020-06-03 [1] CRAN (R 4.0.2)                           
 pkgbuild          1.1.0    2020-07-13 [1] CRAN (R 4.0.2)                           
 pkgconfig         2.0.3    2019-09-22 [1] CRAN (R 4.0.2)                           
 pkgload           1.1.0    2020-05-29 [1] CRAN (R 4.0.2)                           
 plyr            * 1.8.6    2020-03-03 [1] CRAN (R 4.0.2)                           
 png               0.1-7    2013-12-03 [1] CRAN (R 4.0.2)                           
 prettyunits       1.1.1    2020-01-24 [1] CRAN (R 4.0.2)                           
 processx          3.4.5    2020-11-30 [1] CRAN (R 4.0.2)                           
 progress          1.2.2    2019-05-16 [1] CRAN (R 4.0.2)                           
 promises          1.1.1    2020-06-09 [1] CRAN (R 4.0.2)                           
 ps                1.3.3    2020-05-08 [1] CRAN (R 4.0.2)                           
 purrr             0.3.4    2020-04-17 [1] CRAN (R 4.0.2)                           
 R6                2.4.1    2019-11-12 [1] CRAN (R 4.0.2)                           
 radiator        * 1.1.9    2021-01-21 [1] Github (thierrygosselin/radiator@5c6b865)
 randomForestSRC * 2.10.1   2021-02-10 [1] CRAN (R 4.0.2)                           
 raster            3.3-13   2020-07-17 [1] CRAN (R 4.0.2)                           
 RColorBrewer      1.1-2    2014-12-07 [1] CRAN (R 4.0.2)                           
 Rcpp              1.0.5    2020-07-06 [1] CRAN (R 4.0.2)                           
 readr             1.4.0    2020-10-05 [1] CRAN (R 4.0.2)                           
 readxl            1.3.1    2019-03-13 [1] CRAN (R 4.0.2)                           
 remotes           2.2.0    2020-07-21 [1] CRAN (R 4.0.2)                           
 reshape2          1.4.4    2020-04-09 [1] CRAN (R 4.0.2)                           
 rio               0.5.16   2018-11-26 [1] CRAN (R 4.0.2)                           
 rlang             0.4.10   2020-12-30 [1] CRAN (R 4.0.2)                           
 rncl              0.8.4    2020-02-10 [1] CRAN (R 4.0.2)                           
 RNeXML            2.4.5    2020-06-18 [1] CRAN (R 4.0.2)                           
 rprojroot         1.3-2    2018-01-03 [1] CRAN (R 4.0.2)                           
 rstatix           0.6.0    2020-06-18 [1] CRAN (R 4.0.2)                           
 rstudioapi        0.11     2020-02-07 [1] CRAN (R 4.0.2)                           
 scales            1.1.1    2020-05-11 [1] CRAN (R 4.0.2)                           
 seqinr            3.6-1    2019-09-07 [1] CRAN (R 4.0.2)                           
 sessioninfo       1.1.1    2018-11-05 [1] CRAN (R 4.0.2)                           
 sf                0.9-7    2021-01-06 [1] CRAN (R 4.0.2)                           
 shiny             1.6.0    2021-01-25 [1] CRAN (R 4.0.2)                           
 sp                1.4-5    2021-01-10 [1] CRAN (R 4.0.2)                           
 spData            0.3.8    2020-07-03 [1] CRAN (R 4.0.2)                           
 spdep             1.1-5    2020-06-29 [1] CRAN (R 4.0.2)                           
 stringi           1.4.6    2020-02-17 [1] CRAN (R 4.0.2)                           
 stringr           1.4.0    2019-02-10 [1] CRAN (R 4.0.2)                           
 testthat          2.3.2    2020-03-02 [1] CRAN (R 4.0.2)                           
 tibble            3.0.3    2020-07-10 [1] CRAN (R 4.0.2)                           
 tidyr             1.1.2    2020-08-27 [1] CRAN (R 4.0.2)                           
 tidyselect        1.1.0    2020-05-11 [1] CRAN (R 4.0.2)                           
 units             0.6-7    2020-06-13 [1] CRAN (R 4.0.2)                           
 usethis         * 2.0.0    2020-12-10 [1] CRAN (R 4.0.2)                           
 uuid              0.1-4    2020-02-26 [1] CRAN (R 4.0.2)                           
 vcfR            * 1.12.0   2020-07-28 [1] Github (knausb/vcfR@8a61e1c)             
 vctrs             0.3.6    2020-12-17 [1] CRAN (R 4.0.2)                           
 vegan             2.5-6    2019-09-01 [1] CRAN (R 4.0.2)                           
 viridisLite       0.3.0    2018-02-01 [1] CRAN (R 4.0.1)                           
 visNetwork        2.0.9    2019-12-06 [1] CRAN (R 4.0.2)                           
 withr             2.4.0    2021-01-16 [1] CRAN (R 4.0.2)                           
 XML               3.99-0.5 2020-07-23 [1] CRAN (R 4.0.2)                           
 xml2              1.3.2    2020-04-23 [1] CRAN (R 4.0.2)                           
 xtable            1.8-4    2019-04-21 [1] CRAN (R 4.0.2)                           
 yaml              2.2.1    2020-02-01 [1] CRAN (R 4.0.2)                           
 zip               2.1.1    2020-08-27 [1] CRAN (R 4.0.2)                           

[1] /Library/Frameworks/R.framework/Versions/4.0/Resources/library
  • complete data required to reproduce the problem, a subset of it. The data remains confidential.

radiator_genlight391ind_3_realpop.RData.zip

Screenshots
If applicable, add screenshots to help explain your problem.

problem with assignment_ngs function

Hello,

I am trying to use the assignment_ngs function on a genind object and receiving an error message.

Read in genepop file and save as genind object

my_data <-read.genepop("Herring_PopulationStructure_3001loci_301samples.gen", ncode = 2)

my_assignment <- assignment_ngs(my_data,
assignment.analysis = "gsi_sim",
sampling.method == "ranked",
thl = 1,
iteration.method = 10,
subsample = NULL,
iteration.subsample = 10,
common.markers = FALSE,
marker.number = "100",
verbose = TRUE,
folder = NULL,
filename = "assignment_data.txt",
keep.gsi.files = FALSE,
random.seed = NULL,
parallel.core = parallel::detectCores() - 1)

I am receiving the following error message:

Assignment analysis with gsi_sim
Map-independent imputations: no
Error in stringi::stri_join(getwd(), "/", "assignment_analysis_", "method_", :
object 'sampling.method' not found

I would appreciate any help that you could provide.

Best regards,

Eleni

Error: Argument 1 must have names

Hello! I am running the following code in R v3.5.1 using new installs of the radiator and assigner R packages (installed via devtools Sep 14, 2019) on my Mac:

test.tidy = radiator::tidy_genomic_data(data="test.gen", strata="subset_strata.txt")

assign1 <- assigner::assignment_ngs(
data = test.tidy,
assignment.analysis = "gsi_sim",
markers.sampling = "ranked",
thl = 0.2,
iteration.method = 5
)

I get the following error:

##################### assigner::assignment_ngs ################
Execution date/time: 20190914@1348
Assignment analysis with gsi_sim
Folder created: assignment_analysis_method_ranked_20190914@1348
Subsampling: not selected
Conducting Assignment analysis using Training, Holdout, Leave-one-out
Using training samples to rank markers based on Fst
Holdout samples saved in your folder
Starting parallel computations, for progress monitor activity in folder...
Error: Argument 1 must have names

Computation time, overall: 1 sec
###############assignment_ngs completed ############

I've attached my input files (subsets of my full dataset) so that you can recreate the issue. I am using 'test.gen' as input with the attached file, not 'test.txt' (will not let me upload with *.gen file extension). I see an earlier bug report from a user that was getting the same error but changing the file extension did not fix the problem. I've also attached the output from devtools::session_info(). I should also note that I get the same error when attempting to run the same code but using the test datasets provided in the assigner vignettes (data_assigner_sim_01, data_assigner_sim_02). Please let me know if any other information would be helpful! Thanks!

devtools_session_info.txt

subset_strata.txt

test.txt

STRATA_SEQ error with assignment_ngs()

Hello,

Describe the bug
I am having issues when running assignment_ngs() on a genlight object. I load my genlight file output from dartR and get the following error message (see below). I cannot find any reference to STRATA_SEQ in the package code, so I'm having trouble figuring out what my issue is. I get the same issue when using the simulated data from the package: data_assigner_sim_01

To Reproduce

Assign <- assignment_ngs(data=data_assigner_sim_01,
assignment.analysis = "gsi_sim",
marker.number = c(50,100,200,500,1000, "all"),
markers.sampling = "ranked",
thl = 0.2,
iteration.method = 5,
subsample = 15,
iteration.subsample= 3)

Error message:
################################################################################
########################## assigner::assignment_ngs ############################
################################################################################
Execution date/time: 20230614@1021
Assignment analysis with gsi_sim
Calibrating REF/ALT alleles...
Calibrating REF/ALT alleles...
Subsampling: selected
using subsample size of: 15
Error in purrr::map():
In index: 1.
Caused by error in dplyr::group_by():
! Must group by variables found in .data.
✖ Column STRATA_SEQ is not found.
Backtrace:

  1. assigner::assignment_ngs(...)
  2. dplyr:::group_by.data.frame(., STRATA_SEQ)

Computation time, overall: 2 sec
########################## assignment_ngs completed ############################

devtools::session_info()
─ Session info
setting value
version R version 4.3.0 (2023-04-21)
os macOS Monterey 12.5.1
system aarch64, darwin20
ui RStudio
language (EN)
collate en_US.UTF-8
ctype en_US.UTF-8
tz America/New_York
date 2023-06-14
rstudio 2023.03.1+446 Cherry Blossom (desktop)
pandoc 2.19.2 @ /Applications/RStudio.app/Contents/Resources/app/quarto/bin/tools/ (via rmarkdown)

─ Packages
package * version date (UTC) lib source
ade4 * 1.7-22 2023-02-06 [1] CRAN (R 4.3.0)
adegenet * 2.1.10 2023-01-26 [1] CRAN (R 4.3.0)
ape 5.7-1 2023-03-13 [1] CRAN (R 4.3.0)
assigner * 0.5.8 2023-06-13 [1] Github (d39a692)
bit 4.0.5 2022-11-15 [1] CRAN (R 4.3.0)
bit64 4.0.5 2020-08-30 [1] CRAN (R 4.3.0)
cachem 1.0.8 2023-05-01 [1] CRAN (R 4.3.0)
calibrate 1.7.7 2020-06-19 [1] CRAN (R 4.3.0)
callr 3.7.3 2022-11-02 [1] CRAN (R 4.3.0)
cli 3.6.1 2023-03-23 [1] CRAN (R 4.3.0)
cluster 2.1.4 2022-08-22 [1] CRAN (R 4.3.0)
codetools 0.2-19 2023-02-01 [1] CRAN (R 4.3.0)
colorspace 2.1-0 2023-01-23 [1] CRAN (R 4.3.0)
combinat 0.0-8 2012-10-29 [1] CRAN (R 4.3.0)
crayon 1.5.2 2022-09-29 [1] CRAN (R 4.3.0)
dartR * 2.9.7 2023-06-07 [1] CRAN (R 4.3.0)
dartR.data * 1.0.2 2022-11-16 [1] CRAN (R 4.3.0)
data.table * 1.14.8 2023-02-17 [1] CRAN (R 4.3.0)
devtools 2.4.5 2022-10-11 [1] CRAN (R 4.3.0)
digest 0.6.31 2022-12-11 [1] CRAN (R 4.3.0)
dismo 1.3-14 2023-05-21 [1] CRAN (R 4.3.0)
doParallel 1.0.17 2022-02-07 [1] CRAN (R 4.3.0)
dotCall64 1.0-2 2022-10-03 [1] CRAN (R 4.3.0)
dplyr * 1.1.2 2023-04-20 [1] CRAN (R 4.3.0)
ellipsis 0.3.2 2021-04-29 [1] CRAN (R 4.3.0)
evaluate 0.21 2023-05-05 [1] CRAN (R 4.3.0)
fansi 1.0.4 2023-01-22 [1] CRAN (R 4.3.0)
fastmap 1.1.1 2023-02-24 [1] CRAN (R 4.3.0)
fields 14.1 2022-08-12 [1] CRAN (R 4.3.0)
foreach 1.5.2 2022-02-02 [1] CRAN (R 4.3.0)
fs 1.6.2 2023-04-25 [1] CRAN (R 4.3.0)
gap 1.5-1 2023-01-22 [1] CRAN (R 4.3.0)
gap.datasets 0.0.5 2022-05-09 [1] CRAN (R 4.3.0)
gdata 2.19.0 2023-05-05 [1] CRAN (R 4.3.0)
gdistance 1.6.2 2023-04-20 [1] CRAN (R 4.3.0)
gdsfmt 1.36.0 2023-05-08 [1] Bioconductor
generics 0.1.3 2022-07-05 [1] CRAN (R 4.3.0)
genetics 1.3.8.1.3 2021-03-01 [1] CRAN (R 4.3.0)
GGally 2.1.2 2021-06-21 [1] CRAN (R 4.3.0)
ggplot2 * 3.4.2 2023-04-03 [1] CRAN (R 4.3.0)
glue 1.6.2 2022-02-24 [1] CRAN (R 4.3.0)
gridExtra 2.3 2017-09-09 [1] CRAN (R 4.3.0)
gtable 0.3.3 2023-03-21 [1] CRAN (R 4.3.0)
gtools 3.9.4 2022-11-27 [1] CRAN (R 4.3.0)
hms 1.1.3 2023-03-21 [1] CRAN (R 4.3.0)
htmltools 0.5.5 2023-03-23 [1] CRAN (R 4.3.0)
htmlwidgets 1.6.2 2023-03-17 [1] CRAN (R 4.3.0)
httpuv 1.6.11 2023-05-11 [1] CRAN (R 4.3.0)
igraph 1.4.3 2023-05-22 [1] CRAN (R 4.3.0)
iterators 1.0.14 2022-02-05 [1] CRAN (R 4.3.0)
knitr 1.43 2023-05-25 [1] CRAN (R 4.3.0)
later 1.3.1 2023-05-02 [1] CRAN (R 4.3.0)
lattice 0.21-8 2023-04-05 [1] CRAN (R 4.3.0)
lifecycle 1.0.3 2022-10-07 [1] CRAN (R 4.3.0)
magrittr 2.0.3 2022-03-30 [1] CRAN (R 4.3.0)
maps 3.4.1 2022-10-30 [1] CRAN (R 4.3.0)
MASS 7.3-60 2023-05-04 [1] CRAN (R 4.3.0)
Matrix 1.5-4.1 2023-05-18 [1] CRAN (R 4.3.0)
memoise 2.0.1 2021-11-26 [1] CRAN (R 4.3.0)
mgcv 1.8-42 2023-03-02 [1] CRAN (R 4.3.0)
mime 0.12 2021-09-28 [1] CRAN (R 4.3.0)
miniUI 0.1.1.1 2018-05-18 [1] CRAN (R 4.3.0)
mmod 1.3.3 2017-04-06 [1] CRAN (R 4.3.0)
munsell 0.5.0 2018-06-12 [1] CRAN (R 4.3.0)
mvtnorm 1.2-2 2023-06-08 [1] CRAN (R 4.3.0)
nlme 3.1-162 2023-01-31 [1] CRAN (R 4.3.0)
patchwork 1.1.2 2022-08-19 [1] CRAN (R 4.3.0)
pegas 1.2 2023-02-23 [1] CRAN (R 4.3.0)
permute 0.9-7 2022-01-27 [1] CRAN (R 4.3.0)
pillar 1.9.0 2023-03-22 [1] CRAN (R 4.3.0)
pkgbuild 1.4.0 2022-11-27 [1] CRAN (R 4.3.0)
pkgconfig 2.0.3 2019-09-22 [1] CRAN (R 4.3.0)
pkgload 1.3.2 2022-11-16 [1] CRAN (R 4.3.0)
plyr 1.8.8 2022-11-11 [1] CRAN (R 4.3.0)
png 0.1-8 2022-11-29 [1] CRAN (R 4.3.0)
PopGenReport 3.0.7 2022-05-27 [1] CRAN (R 4.3.0)
prettyunits 1.1.1 2020-01-24 [1] CRAN (R 4.3.0)
processx 3.8.1 2023-04-18 [1] CRAN (R 4.3.0)
profvis 0.3.8 2023-05-02 [1] CRAN (R 4.3.0)
promises 1.2.0.1 2021-02-11 [1] CRAN (R 4.3.0)
ps 1.7.5 2023-04-18 [1] CRAN (R 4.3.0)
purrr * 1.0.1 2023-01-10 [1] CRAN (R 4.3.0)
R.methodsS3 1.8.2 2022-06-13 [1] CRAN (R 4.3.0)
R.oo 1.25.0 2022-06-12 [1] CRAN (R 4.3.0)
R.utils 2.12.2 2022-11-11 [1] CRAN (R 4.3.0)
R6 2.5.1 2021-08-19 [1] CRAN (R 4.3.0)
radiator 1.2.8 2023-06-06 [1] Github (thierrygosselin/radiator@d2442e5)
raster 3.6-20 2023-03-06 [1] CRAN (R 4.3.0)
RColorBrewer 1.1-3 2022-04-03 [1] CRAN (R 4.3.0)
Rcpp 1.0.10 2023-01-22 [1] CRAN (R 4.3.0)
readr 2.1.4 2023-02-10 [1] CRAN (R 4.3.0)
remotes 2.4.2 2021-11-30 [1] CRAN (R 4.3.0)
reshape 0.8.9 2022-04-12 [1] CRAN (R 4.3.0)
reshape2 1.4.4 2020-04-09 [1] CRAN (R 4.3.0)
rgdal 1.6-7 2023-05-31 [1] CRAN (R 4.3.0)
RgoogleMaps 1.4.5.3 2020-02-12 [1] CRAN (R 4.3.0)
rlang 1.1.1 2023-04-28 [1] CRAN (R 4.3.0)
rmarkdown 2.22 2023-06-01 [1] CRAN (R 4.3.0)
rstudioapi 0.14 2022-08-22 [1] CRAN (R 4.3.0)
scales 1.2.1 2022-08-20 [1] CRAN (R 4.3.0)
seqinr 4.2-30 2023-04-05 [1] CRAN (R 4.3.0)
sessioninfo 1.2.2 2021-12-06 [1] CRAN (R 4.3.0)
shiny 1.7.4 2022-12-15 [1] CRAN (R 4.3.0)
SNPRelate 1.34.1 2023-05-08 [1] Bioconductor
sp 1.6-1 2023-05-31 [1] CRAN (R 4.3.0)
spam 2.9-1 2022-08-07 [1] CRAN (R 4.3.0)
StAMPP 1.6.3 2021-08-08 [1] CRAN (R 4.3.0)
stringi 1.7.12 2023-01-11 [1] CRAN (R 4.3.0)
stringr 1.5.0 2022-12-02 [1] CRAN (R 4.3.0)
terra 1.7-29 2023-04-22 [1] CRAN (R 4.3.0)
tibble 3.2.1 2023-03-20 [1] CRAN (R 4.3.0)
tidyr 1.3.0 2023-01-24 [1] CRAN (R 4.3.0)
tidyselect 1.2.0 2022-10-10 [1] CRAN (R 4.3.0)
tzdb 0.4.0 2023-05-12 [1] CRAN (R 4.3.0)
urlchecker 1.0.1 2021-11-30 [1] CRAN (R 4.3.0)
usethis 2.2.0 2023-06-06 [1] CRAN (R 4.3.0)
utf8 1.2.3 2023-01-31 [1] CRAN (R 4.3.0)
vctrs 0.6.2 2023-04-19 [1] CRAN (R 4.3.0)
vegan 2.6-4 2022-10-11 [1] CRAN (R 4.3.0)
viridis 0.6.3 2023-05-03 [1] CRAN (R 4.3.0)
viridisLite 0.4.2 2023-05-02 [1] CRAN (R 4.3.0)
vroom 1.6.3 2023-04-28 [1] CRAN (R 4.3.0)
withr 2.5.0 2022-03-03 [1] CRAN (R 4.3.0)
xfun 0.39 2023-04-20 [1] CRAN (R 4.3.0)
xtable 1.8-4 2019-04-21 [1] CRAN (R 4.3.0)
yaml 2.3.7 2023-01-23 [1] CRAN (R 4.3.0)

[1] /Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library

5 nodes produced errors; first error: error writing to connection

Hi Thierry,

I'm gettting the error message below when attempting to run assignment_ngs in RStudio. I read through the older issues and found one similar, but there was no resolution posted. Based on that issue though, I ran detect Cores() , which shows 8 cores, and then tried running the code with parallel.core = 1. When I run assignment_ngs with more cores, I get more nodes producing more errors (5 vs. 1). Any help would be greatly appreciated. I attached the populations folder, but it would not let me attach the vcf. Thanks in advance!

Best,
Justine Whitaker

STL.vcf2=read_vcf('STLpopulations.snps.vcf', strata = 'StLaw_popmapFINAL.txt', parallel.core = 1)

test2 <- assigner::assignment_ngs(data = STL.vcf2, assignment.analysis = "gsi_sim", markers.sampling = "ranked", thl = 0.2, iteration.method = 5, marker.number = c(100, 200, 300, 400, "all"), subsample = 20, iteration.subsample = 3, parallel.core = 1)

assigner::assignment_ngs ############################ ################################################################################ Execution date/time: 20200406@1332 Assignment analysis with gsi_sim Folder created: assignment_analysis_method_ranked_20200406@1332 Computation time, overall: 8 sec Calibrating REF/ALT alleles... number of REF/ALT switch = 21 Subsampling: selected using subsample size of: 20 Analyzing subsample: 1 Conducting Assignment analysis using Training, Holdout, Leave-one-out Using training samples to rank markers based on Fst Holdout samples saved in your folder Starting parallel computations, for progress monitor activity in folder... Error in checkForRemoteErrors(val) : one node produced an error: 'assignment_data_iteration_1_markers_100.output.txt' does not exist in current working directory ('C:/Users/justi/Documents/Fisheries Research Revisions/assignPOP/assignment_analysis_method_ranked_20200406@1332/subsample_1/assignment_1'). In addition: Warning messages: 1: In serialize(data, node$con) : 'package:stats' may not be available when loading 2: In serialize(data, node$con) : 'package:stats' may not be available when loading 3: In serialize(data, node$con) : 'package:stats' may not be available when loading 4: In serialize(data, node$con) : 'package:stats' may not be available when loading 5: In serialize(data, node$con) : 'package:stats' may not be available when loading 6: In serialize(data, node$con) : 'package:stats' may not be available when loading Computation time, overall: 118 sec ########################## assignment_ngs completed ############################

 

| >

parallel::detectCores()
[1] 8

devtools::session_info()
Registered S3 method overwritten by 'cli':
method from
print.tree tree

  • Session info ------------------------------------------------------------------------------------------------------------------------------
    setting value
    version R version 3.6.3 (2020-02-29)
    os Windows 10 x64
    system x86_64, mingw32
    ui RStudio
    language (EN)
    collate English_United States.1252
    ctype English_United States.1252
    tz America/Chicago
    date 2020-04-06

  • Packages ----------------------------------------------------------------------------------------------------------------------------------
    package * version date lib source
    ade4 * 1.7-15 2020-02-13 [1] CRAN (R 3.6.3)
    adegenet * 2.1.2 2020-01-20 [1] CRAN (R 3.6.3)
    ape 5.3 2019-03-17 [1] CRAN (R 3.6.3)
    assertthat 0.2.1 2019-03-21 [1] CRAN (R 3.6.3)
    assigner * 0.5.7 2020-04-03 [1] Github (1888222)
    assignPOP * 1.1.9 2020-03-16 [1] CRAN (R 3.6.3)
    backports 1.1.5 2019-10-02 [1] CRAN (R 3.6.1)
    Biobase 2.46.0 2019-10-29 [1] Bioconductor
    BiocGenerics 0.32.0 2019-10-29 [1] Bioconductor
    Biostrings 2.54.0 2019-10-29 [1] Bioconductor
    bitops 1.0-6 2013-08-17 [1] CRAN (R 3.6.0)
    boot 1.3-24 2019-12-20 [2] CRAN (R 3.6.3)
    broom 0.5.5 2020-02-29 [1] CRAN (R 3.6.3)
    calibrate 1.7.5 2019-10-01 [1] CRAN (R 3.6.3)
    callr 3.4.3 2020-03-28 [1] CRAN (R 3.6.3)
    caret 6.0-86 2020-03-20 [1] CRAN (R 3.6.3)
    class 7.3-15 2019-01-01 [2] CRAN (R 3.6.3)
    classInt 0.4-2 2019-10-17 [1] CRAN (R 3.6.3)
    cli 2.0.2 2020-02-28 [1] CRAN (R 3.6.3)
    cluster 2.1.0 2019-06-19 [2] CRAN (R 3.6.3)
    coda 0.19-3 2019-07-05 [1] CRAN (R 3.6.3)
    codetools 0.2-16 2018-12-24 [2] CRAN (R 3.6.3)
    colorspace 1.4-1 2019-03-18 [1] CRAN (R 3.6.1)
    combinat 0.0-8 2012-10-29 [1] CRAN (R 3.6.0)
    crayon 1.3.4 2017-09-16 [1] CRAN (R 3.6.3)
    crosstalk 1.1.0.1 2020-03-13 [1] CRAN (R 3.6.3)
    dartR * 1.1.11 2019-02-07 [1] CRAN (R 3.6.3)
    data.table 1.12.8 2019-12-09 [1] CRAN (R 3.6.3)
    DBI 1.1.0 2019-12-15 [1] CRAN (R 3.6.3)
    deldir 0.1-25 2020-02-03 [1] CRAN (R 3.6.2)
    desc 1.2.0 2018-05-01 [1] CRAN (R 3.6.3)
    devtools 2.2.2 2020-02-17 [1] CRAN (R 3.6.3)
    digest 0.6.25 2020-02-23 [1] CRAN (R 3.6.3)
    directlabels 2020.1.31 2020-02-01 [1] CRAN (R 3.6.3)
    dismo 1.1-4 2017-01-09 [1] CRAN (R 3.6.3)
    doParallel 1.0.15 2019-08-02 [1] CRAN (R 3.6.3)
    dplyr 0.8.5 2020-03-07 [1] CRAN (R 3.6.3)
    e1071 1.7-3 2019-11-26 [1] CRAN (R 3.6.3)
    ellipse 0.4.1 2018-01-05 [1] CRAN (R 3.6.3)
    ellipsis 0.3.0 2019-09-20 [1] CRAN (R 3.6.3)
    expm 0.999-4 2019-03-21 [1] CRAN (R 3.6.3)
    fansi 0.4.1 2020-01-08 [1] CRAN (R 3.6.3)
    farver 2.0.3 2020-01-16 [1] CRAN (R 3.6.3)
    fastmap 1.0.1 2019-10-08 [1] CRAN (R 3.6.3)
    foreach 1.5.0 2020-03-30 [1] CRAN (R 3.6.3)
    fs 1.4.0 2020-03-31 [1] CRAN (R 3.6.3)
    gap 1.2.2 2020-02-02 [1] CRAN (R 3.6.3)
    gdata 2.18.0 2017-06-06 [1] CRAN (R 3.6.2)
    gdistance 1.3-1 2020-02-29 [1] CRAN (R 3.6.3)
    gdsfmt 1.22.0 2019-10-29 [1] Bioconductor
    generics 0.0.2 2018-11-29 [1] CRAN (R 3.6.3)
    genetics 1.3.8.1.2 2019-04-22 [1] CRAN (R 3.6.3)
    GenomeInfoDb 1.22.1 2020-03-27 [1] Bioconductor
    GenomeInfoDbData 1.2.2 2020-04-03 [1] Bioconductor
    GenomicRanges 1.38.0 2019-10-29 [1] Bioconductor
    GGally 1.5.0 2020-03-25 [1] CRAN (R 3.6.3)
    ggplot2 3.3.0 2020-03-05 [1] CRAN (R 3.6.3)
    glue 1.3.2 2020-03-12 [1] CRAN (R 3.6.3)
    gmodels 2.18.1 2018-06-25 [1] CRAN (R 3.6.3)
    gower 0.2.1 2019-05-14 [1] CRAN (R 3.6.1)
    gridExtra 2.3 2017-09-09 [1] CRAN (R 3.6.3)
    gtable 0.3.0 2019-03-25 [1] CRAN (R 3.6.3)
    gtools 3.8.1 2018-06-26 [1] CRAN (R 3.6.0)
    GWASExactHW 1.01 2013-01-05 [1] CRAN (R 3.6.0)
    hierfstat 0.04-22 2015-12-04 [1] CRAN (R 3.6.3)
    hms 0.5.3 2020-01-08 [1] CRAN (R 3.6.3)
    htmltools 0.4.0 2019-10-04 [1] CRAN (R 3.6.3)
    htmlwidgets 1.5.1 2019-10-08 [1] CRAN (R 3.6.3)
    httpuv 1.5.2 2019-09-11 [1] CRAN (R 3.6.3)
    igraph 1.2.5 2020-03-19 [1] CRAN (R 3.6.3)
    ipred 0.9-9 2019-04-28 [1] CRAN (R 3.6.3)
    IRanges 2.20.2 2020-01-13 [1] Bioconductor
    iterators 1.0.12 2019-07-26 [1] CRAN (R 3.6.3)
    jsonlite 1.6.1 2020-02-02 [1] CRAN (R 3.6.3)
    KernSmooth 2.23-16 2019-10-15 [2] CRAN (R 3.6.3)
    knitr 1.28 2020-02-06 [1] CRAN (R 3.6.3)
    labeling 0.3 2014-08-23 [1] CRAN (R 3.6.0)
    later 1.0.0 2019-10-04 [1] CRAN (R 3.6.3)
    lattice 0.20-38 2018-11-04 [2] CRAN (R 3.6.3)
    lava 1.6.7 2020-03-05 [1] CRAN (R 3.6.3)
    leaflet 2.0.3 2019-11-16 [1] CRAN (R 3.6.3)
    LearnBayes 2.15.1 2018-03-18 [1] CRAN (R 3.6.0)
    lifecycle 0.2.0 2020-03-06 [1] CRAN (R 3.6.3)
    logistf 1.23 2018-07-19 [1] CRAN (R 3.6.3)
    lubridate 1.7.4 2018-04-11 [1] CRAN (R 3.6.3)
    magrittr 1.5 2014-11-22 [1] CRAN (R 3.6.3)
    manipulateWidget 0.10.1 2020-02-24 [1] CRAN (R 3.6.3)
    MASS 7.3-51.5 2019-12-20 [2] CRAN (R 3.6.3)
    Matrix 1.2-18 2019-11-27 [2] CRAN (R 3.6.3)
    memoise 1.1.0 2017-04-21 [1] CRAN (R 3.6.3)
    memuse 4.1-0 2020-02-17 [1] CRAN (R 3.6.2)
    mgcv 1.8-31 2019-11-09 [2] CRAN (R 3.6.3)
    mice 3.8.0 2020-02-21 [1] CRAN (R 3.6.3)
    mime 0.9 2020-02-04 [1] CRAN (R 3.6.2)
    miniUI 0.1.1.1 2018-05-18 [1] CRAN (R 3.6.3)
    mmod 1.3.3 2017-04-06 [1] CRAN (R 3.6.3)
    ModelMetrics 1.2.2.2 2020-03-17 [1] CRAN (R 3.6.3)
    munsell 0.5.0 2018-06-12 [1] CRAN (R 3.6.3)
    mvtnorm 1.1-0 2020-02-24 [1] CRAN (R 3.6.2)
    nlme 3.1-144 2020-02-06 [2] CRAN (R 3.6.3)
    nnet 7.3-12 2016-02-02 [2] CRAN (R 3.6.3)
    pbmcapply 1.5.0 2019-07-10 [1] CRAN (R 3.6.1)
    pca3d 0.10.1 2019-12-14 [1] CRAN (R 3.6.3)
    pegas 0.13 2020-03-10 [1] CRAN (R 3.6.3)
    permute 0.9-5 2019-03-12 [1] CRAN (R 3.6.3)
    pillar 1.4.3 2019-12-20 [1] CRAN (R 3.6.3)
    pinfsc50 1.1.0 2016-12-02 [1] CRAN (R 3.6.0)
    pkgbuild 1.0.6 2019-10-09 [1] CRAN (R 3.6.3)
    pkgconfig 2.0.3 2019-09-22 [1] CRAN (R 3.6.3)
    pkgload 1.0.2 2018-10-29 [1] CRAN (R 3.6.3)
    plyr 1.8.6 2020-03-03 [1] CRAN (R 3.6.3)
    png 0.1-7 2013-12-03 [1] CRAN (R 3.6.0)
    PopGenReport 3.0.4 2019-02-04 [1] CRAN (R 3.6.3)
    prettyunits 1.1.1 2020-01-24 [1] CRAN (R 3.6.3)
    pROC 1.16.2 2020-03-19 [1] CRAN (R 3.6.3)
    processx 3.4.2 2020-02-09 [1] CRAN (R 3.6.3)
    prodlim 2019.11.13 2019-11-17 [1] CRAN (R 3.6.3)
    promises 1.1.0 2019-10-04 [1] CRAN (R 3.6.3)
    ps 1.3.2 2020-02-13 [1] CRAN (R 3.6.3)
    purrr 0.3.3 2019-10-18 [1] CRAN (R 3.6.3)
    quadprog 1.5-8 2019-11-20 [1] CRAN (R 3.6.1)
    qvalue 2.18.0 2019-10-29 [1] Bioconductor
    R.methodsS3 1.8.0 2020-02-14 [1] CRAN (R 3.6.2)
    R.oo 1.23.0 2019-11-03 [1] CRAN (R 3.6.2)
    R.utils 2.9.2 2019-12-08 [1] CRAN (R 3.6.3)
    R6 2.4.1 2019-11-12 [1] CRAN (R 3.6.3)
    radiator * 1.1.5 2020-04-03 [1] Github (thierrygosselin/radiator@a13fe0a)
    randomForest 4.6-14 2018-03-25 [1] CRAN (R 3.6.3)
    raster 3.0-12 2020-01-30 [1] CRAN (R 3.6.3)
    RColorBrewer 1.1-2 2014-12-07 [1] CRAN (R 3.6.0)
    Rcpp 1.0.4 2020-03-17 [1] CRAN (R 3.6.3)
    RCurl 1.98-1.1 2020-01-19 [1] CRAN (R 3.6.2)
    readr 1.3.1 2018-12-21 [1] CRAN (R 3.6.3)
    recipes 0.1.10 2020-03-18 [1] CRAN (R 3.6.3)
    remotes 2.1.1 2020-02-15 [1] CRAN (R 3.6.3)
    reshape 0.8.8 2018-10-23 [1] CRAN (R 3.6.3)
    reshape2 1.4.3 2017-12-11 [1] CRAN (R 3.6.3)
    rgdal 1.4-8 2019-11-27 [1] CRAN (R 3.6.3)
    rgl 0.100.50 2020-02-21 [1] CRAN (R 3.6.3)
    RgoogleMaps 1.4.5.3 2020-02-12 [1] CRAN (R 3.6.3)
    rlang 0.4.5 2020-03-01 [1] CRAN (R 3.6.3)
    rpart 4.1-15 2019-04-12 [2] CRAN (R 3.6.3)
    rprojroot 1.3-2 2018-01-03 [1] CRAN (R 3.6.3)
    rrBLUP 4.6.1 2019-12-18 [1] CRAN (R 3.6.2)
    rstudioapi 0.11 2020-02-07 [1] CRAN (R 3.6.3)
    S4Vectors 0.24.3 2020-01-18 [1] Bioconductor
    scales 1.1.0 2019-11-18 [1] CRAN (R 3.6.3)
    SeqArray 1.26.2 2019-12-26 [1] Bioconductor
    seqinr 3.6-1 2019-09-07 [1] CRAN (R 3.6.3)
    SeqVarTools 1.24.1 2020-03-17 [1] Bioconductor
    sessioninfo 1.1.1 2018-11-05 [1] CRAN (R 3.6.3)
    sf 0.9-0 2020-03-24 [1] CRAN (R 3.6.3)
    shiny 1.4.0.2 2020-03-13 [1] CRAN (R 3.6.3)
    SNPRelate 1.20.1 2019-11-22 [1] Bioconductor
    sp 1.4-1 2020-02-28 [1] CRAN (R 3.6.3)
    spData 0.3.3 2020-02-11 [1] CRAN (R 3.6.3)
    spdep 1.1-3 2019-09-18 [1] CRAN (R 3.6.3)
    StAMPP 1.6.1 2020-03-20 [1] CRAN (R 3.6.3)
    stringi 1.4.6 2020-02-17 [1] CRAN (R 3.6.2)
    stringr 1.4.0 2019-02-10 [1] CRAN (R 3.6.3)
    survival 3.1-8 2019-12-03 [2] CRAN (R 3.6.3)
    testthat 2.3.2 2020-03-02 [1] CRAN (R 3.6.3)
    tibble 2.1.3 2019-06-06 [1] CRAN (R 3.6.3)
    tidyr 1.0.2 2020-01-24 [1] CRAN (R 3.6.3)
    tidyselect 1.0.0 2020-01-27 [1] CRAN (R 3.6.3)
    timeDate 3043.102 2018-02-21 [1] CRAN (R 3.6.2)
    tree 1.0-40 2019-03-01 [1] CRAN (R 3.6.3)
    units 0.6-6 2020-03-16 [1] CRAN (R 3.6.3)
    UpSetR 1.4.0 2019-05-22 [1] CRAN (R 3.6.3)
    usethis 1.5.1 2019-07-04 [1] CRAN (R 3.6.3)
    vcfR * 1.10.0 2020-02-06 [1] CRAN (R 3.6.3)
    vctrs 0.2.4 2020-03-10 [1] CRAN (R 3.6.3)
    vegan 2.5-6 2019-09-01 [1] CRAN (R 3.6.3)
    viridisLite 0.3.0 2018-02-01 [1] CRAN (R 3.6.3)
    webshot 0.5.2 2019-11-22 [1] CRAN (R 3.6.3)
    withr 2.1.2 2018-03-15 [1] CRAN (R 3.6.3)
    xfun 0.12 2020-01-13 [1] CRAN (R 3.6.3)
    xtable 1.8-4 2019-04-21 [1] CRAN (R 3.6.3)
    XVector 0.26.0 2019-10-29 [1] Bioconductor
    zlibbioc 1.32.0 2019-10-29 [1] Bioconductor

[1] C:/Users/justi/Documents/R/win-library/3.6
[2] C:/Program Files/R/R-3.6.3/library

[StLaw_popmapFINAL.txt]

(https://github.com/thierrygosselin/assigner/files/4440233/StLaw_popmapFINAL.txt)

Error in checkForRemoteErrors(val) : 3 nodes produced errors

Describe the bug
When I tried to work through the first example on http://thierrygosselin.github.io/assigner/articles/get_started.html (Data 1: high structure), I always got the following error messages (see below).

To Reproduce
Include the steps to reproduce the behavior:

  • the exact command (function, arguments, values) used:
    test1 <- assigner::assignment_ngs(
    data = data,
    assignment.analysis = "gsi_sim",
    markers.sampling = "ranked",
    thl = 0.2,
    iteration.method = 5
    )
  • the complete error message you're getting
    Error in checkForRemoteErrors(val) :
    3 nodes produced errors; first error: 'assignment_data_iteration_1_markers_497.output.txt' does not exist in current working directory ('C:/Users/gp/Documents/assignment_analysis_method_ranked_20190808@1453/assignment_1').
    In addition: There were 18 warnings (use warnings() to see them)

Computation time, overall: 577 sec
########################## assignment_ngs completed ############################

warnings()
Warnmeldungen:
1: In serialize(data, node$con) :
'package:stats' may not be available when loading
2: In serialize(data, node$con) :
'package:stats' may not be available when loading
3: In serialize(data, node$con) :
'package:stats' may not be available when loading
4: In serialize(data, node$con) :
'package:stats' may not be available when loading
5: In serialize(data, node$con) :
'package:stats' may not be available when loading
6: In serialize(data, node$con) :
'package:stats' may not be available when loading
7: In serialize(data, node$con) :
'package:stats' may not be available when loading
8: In serialize(data, node$con) :
'package:stats' may not be available when loading
9: In serialize(data, node$con) :
'package:stats' may not be available when loading
10: In serialize(data, node$con) :
'package:stats' may not be available when loading
11: In serialize(data, node$con) :
'package:stats' may not be available when loading
12: In serialize(data, node$con) :
'package:stats' may not be available when loading
13: In serialize(data, node$con) :
'package:stats' may not be available when loading
14: In serialize(data, node$con) :
'package:stats' may not be available when loading
15: In serialize(data, node$con) :
'package:stats' may not be available when loading
16: In serialize(data, node$con) :
'package:stats' may not be available when loading
17: In serialize(data, node$con) :
'package:stats' may not be available when loading
18: In serialize(data, node$con) :
'package:stats' may not be available when loading
(truncated here)

  • the output of devtools::session_info()

devtools::session_info()

  • Session info --------------------------------------------------------------------------------------------------------------------------------
    setting value
    version R version 3.6.1 (2019-07-05)
    os Windows 7 x64 SP 1
    system x86_64, mingw32
    ui RStudio
    language (EN)
    collate German_Switzerland.1252
    ctype German_Switzerland.1252
    tz Europe/Berlin
    date 2019-08-08

  • Packages ------------------------------------------------------------------------------------------------------------------------------------
    package * version date lib source
    ade4 1.7-13 2018-08-31 [1] CRAN (R 3.6.1)
    adegenet 2.1.1 2018-02-02 [1] CRAN (R 3.6.1)
    ape 5.3 2019-03-17 [1] CRAN (R 3.6.1)
    assertthat 0.2.1 2019-03-21 [1] CRAN (R 3.6.1)
    assigner * 0.5.6 2019-08-08 [1] Github (b941111)
    backports 1.1.4 2019-04-10 [1] CRAN (R 3.6.0)
    boot 1.3-22 2019-04-02 [2] CRAN (R 3.6.1)
    callr 3.3.1 2019-07-18 [1] CRAN (R 3.6.1)
    class 7.3-15 2019-01-01 [2] CRAN (R 3.6.1)
    classInt 0.3-3 2019-04-26 [1] CRAN (R 3.6.1)
    cli 1.1.0 2019-03-19 [1] CRAN (R 3.6.1)
    cluster 2.1.0 2019-06-19 [2] CRAN (R 3.6.1)
    coda 0.19-3 2019-07-05 [1] CRAN (R 3.6.1)
    colorspace 1.4-1 2019-03-18 [1] CRAN (R 3.6.1)
    crayon 1.3.4 2017-09-16 [1] CRAN (R 3.6.1)
    curl 4.0 2019-07-22 [1] CRAN (R 3.6.1)
    DBI 1.0.0 2018-05-02 [1] CRAN (R 3.6.1)
    deldir 0.1-23 2019-07-31 [1] CRAN (R 3.6.1)
    desc 1.2.0 2018-05-01 [1] CRAN (R 3.6.1)
    devtools * 2.1.0 2019-07-06 [1] CRAN (R 3.6.1)
    digest 0.6.20 2019-07-04 [1] CRAN (R 3.6.1)
    dplyr 0.8.3 2019-07-04 [1] CRAN (R 3.6.1)
    e1071 1.7-2 2019-06-05 [1] CRAN (R 3.6.1)
    expm 0.999-4 2019-03-21 [1] CRAN (R 3.6.1)
    fs 1.3.1 2019-05-06 [1] CRAN (R 3.6.1)
    gdata 2.18.0 2017-06-06 [1] CRAN (R 3.6.0)
    ggplot2 3.2.0 2019-06-16 [1] CRAN (R 3.6.0)
    glue 1.3.1 2019-03-12 [1] CRAN (R 3.6.1)
    gmodels 2.18.1 2018-06-25 [1] CRAN (R 3.6.1)
    gtable 0.3.0 2019-03-25 [1] CRAN (R 3.6.1)
    gtools 3.8.1 2018-06-26 [1] CRAN (R 3.6.0)
    hms 0.5.0 2019-07-09 [1] CRAN (R 3.6.1)
    htmltools 0.3.6 2017-04-28 [1] CRAN (R 3.6.1)
    httpuv 1.5.1 2019-04-05 [1] CRAN (R 3.6.1)
    igraph 1.2.4.1 2019-04-22 [1] CRAN (R 3.6.1)
    KernSmooth 2.23-15 2015-06-29 [2] CRAN (R 3.6.1)
    later 0.8.0 2019-02-11 [1] CRAN (R 3.6.1)
    lattice 0.20-38 2018-11-04 [2] CRAN (R 3.6.1)
    lazyeval 0.2.2 2019-03-15 [1] CRAN (R 3.6.1)
    LearnBayes 2.15.1 2018-03-18 [1] CRAN (R 3.6.0)
    magrittr 1.5 2014-11-22 [1] CRAN (R 3.6.1)
    MASS 7.3-51.4 2019-03-31 [2] CRAN (R 3.6.1)
    Matrix 1.2-17 2019-03-22 [2] CRAN (R 3.6.1)
    memoise 1.1.0 2017-04-21 [1] CRAN (R 3.6.1)
    mgcv 1.8-28 2019-03-21 [2] CRAN (R 3.6.1)
    mime 0.7 2019-06-11 [1] CRAN (R 3.6.0)
    munsell 0.5.0 2018-06-12 [1] CRAN (R 3.6.1)
    nlme 3.1-140 2019-05-12 [2] CRAN (R 3.6.1)
    pbmcapply 1.5.0 2019-07-10 [1] CRAN (R 3.6.1)
    permute 0.9-5 2019-03-12 [1] CRAN (R 3.6.1)
    pillar 1.4.2 2019-06-29 [1] CRAN (R 3.6.1)
    pkgbuild 1.0.4 2019-08-05 [1] CRAN (R 3.6.1)
    pkgconfig 2.0.2 2018-08-16 [1] CRAN (R 3.6.1)
    pkgload 1.0.2 2018-10-29 [1] CRAN (R 3.6.1)
    plyr 1.8.4 2016-06-08 [1] CRAN (R 3.6.1)
    prettyunits 1.0.2 2015-07-13 [1] CRAN (R 3.6.1)
    processx 3.4.1 2019-07-18 [1] CRAN (R 3.6.1)
    promises 1.0.1 2018-04-13 [1] CRAN (R 3.6.1)
    ps 1.3.0 2018-12-21 [1] CRAN (R 3.6.1)
    purrr 0.3.2 2019-03-15 [1] CRAN (R 3.6.1)
    R6 2.4.0 2019-02-14 [1] CRAN (R 3.6.1)
    radiator 1.1.1 2019-08-08 [1] Github (thierrygosselin/radiator@d79b062)
    Rcpp 1.0.2 2019-07-25 [1] CRAN (R 3.6.1)
    readr 1.3.1 2018-12-21 [1] CRAN (R 3.6.1)
    remotes 2.1.0 2019-06-24 [1] CRAN (R 3.6.1)
    reshape2 1.4.3 2017-12-11 [1] CRAN (R 3.6.1)
    rlang 0.4.0 2019-06-25 [1] CRAN (R 3.6.1)
    rprojroot 1.3-2 2018-01-03 [1] CRAN (R 3.6.1)
    rstudioapi 0.10 2019-03-19 [1] CRAN (R 3.6.1)
    scales 1.0.0 2018-08-09 [1] CRAN (R 3.6.1)
    seqinr 3.4-5 2017-08-01 [1] CRAN (R 3.6.1)
    sessioninfo 1.1.1 2018-11-05 [1] CRAN (R 3.6.1)
    sf 0.7-7 2019-07-24 [1] CRAN (R 3.6.1)
    shiny 1.3.2 2019-04-22 [1] CRAN (R 3.6.1)
    sp 1.3-1 2018-06-05 [1] CRAN (R 3.6.1)
    spData 0.3.0 2019-01-07 [1] CRAN (R 3.6.1)
    spdep 1.1-2 2019-04-05 [1] CRAN (R 3.6.1)
    stringi 1.4.3 2019-03-12 [1] CRAN (R 3.6.0)
    stringr 1.4.0 2019-02-10 [1] CRAN (R 3.6.1)
    testthat 2.2.1 2019-07-25 [1] CRAN (R 3.6.1)
    tibble 2.1.3 2019-06-06 [1] CRAN (R 3.6.1)
    tidyselect 0.2.5 2018-10-11 [1] CRAN (R 3.6.1)
    units 0.6-3 2019-05-03 [1] CRAN (R 3.6.1)
    usethis * 1.5.1 2019-07-04 [1] CRAN (R 3.6.1)
    vctrs 0.2.0 2019-07-05 [1] CRAN (R 3.6.1)
    vegan 2.5-5 2019-05-12 [1] CRAN (R 3.6.1)
    withr 2.1.2 2018-03-15 [1] CRAN (R 3.6.1)
    xtable 1.8-4 2019-04-21 [1] CRAN (R 3.6.1)
    zeallot 0.1.0 2018-01-28 [1] CRAN (R 3.6.1)

[1] C:/Users/gp/Documents/R/win-library/3.6
[2] C:/Program Files/R/R-3.6.1/library

  • complete data required to reproduce the problem, a subset of it. The data remains confidential.
    data set from the example, obtained via the command
    data <- data_assigner_sim_01

Screenshots
grafik

Release assigner 1.0.0

Prepare for release:

  • Check that description is informative
  • Check licensing of included files
  • usethis::use_cran_comments()
  • radiator accepted on CRAN
  • remove Remotes in DESCRIPTION
  • devtools::check()
  • devtools::check_win_devel()
  • rhub::check_for_cran()
  • Polish pkgdown reference index
  • Draft blog post

Submit to CRAN:

  • usethis::use_version('major')
  • Update cran-comments.md
  • devtools::submit_cran()
  • Approve email

Wait for CRAN...

  • Accepted 🎉
  • usethis::use_github_release()
  • usethis::use_dev_version()
  • usethis::use_news()
  • Update install instructions in README
  • Finish blog post
  • Tweet
  • Add link to blog post in pkgdown news menu

Error: object "MARKERS" not found

I am trying to re-run some analyses that I did a few months ago, using assigner with gsi_sim in RStudio on a linux machine. After installing assigner and gsi_sim from within RStudio and then attempting to run the function assignment_ngs, I am receiving the error message:

Error in mutate_impl(.data, dots) : Evaluation error: object 'MARKERS' not found.

I have tried removing and re-installing assigner and gsi_sim, as well as each required package. I have checked my genepop file to make sure that the error is not in my input file, and all seems fine. I'm at a bit of a loss as to what the error message means; any help is much appreciated! I attached the code that I am working with for reference.

Assigner_wGSIsim_linux.txt

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.