Error in rep(lab, vec) : invalid 'times' argument

105 views
Skip to first unread message

Serina

unread,
Oct 6, 2022, 3:08:24 AM10/6/22
to poppr
Hi all,

I'm trying to run the commands genotype_curve and locus_table for my micro-satellite data and I keep receiving this error "Error in rep(lab, vec) : invalid 'times' argument"

I have an older file (different data) that is formatted in the exact same way (GenAlex.csv format) and I have no problems with the commands, so I feel stumped at how to troubleshoot this error. Any help at all would be greatly appreciated!

thank you






Serina

unread,
Oct 6, 2022, 3:12:37 AM10/6/22
to poppr
To clarify, the file is in genind format as it was read in with the read.genalex function. I can use the info.table function with no errors.

Zhian Kamvar

unread,
Oct 6, 2022, 10:20:16 AM10/6/22
to Serina, poppr
Hi Serina, 

This sounds like a bug, could you send me the file you are having trouble with and the commands you used when you got the error? Unfortunately, this is one of those situations where I cannot accurately diagnose the problem without seeing the data. 

Best, 
Zhian

--
You received this message because you are subscribed to the Google Groups "poppr" group.
To unsubscribe from this group and stop receiving emails from it, send an email to poppr+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/poppr/e13c4ecd-3de1-4bc9-ba54-86c7149ff8d6n%40googlegroups.com.
Message has been deleted

Serina

unread,
Oct 6, 2022, 9:12:20 PM10/6/22
to poppr
{ > sessionInfo()
R version 3.6.2 (2019-12-12)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Catalina 10.15.7

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib

locale:
[1] en_AU.UTF-8/en_AU.UTF-8/en_AU.UTF-8/C/en_AU.UTF-8/en_AU.UTF-8

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

other attached packages:
[1] PopGenReport_3.0.4 knitr_1.30         magrittr_1.5       poppr_2.8.6      
[5] adegenet_2.1.3     ade4_1.7-15      

loaded via a namespace (and not attached):
 [1] nlme_3.1-149        sf_0.9-6            gmodels_2.18.1      RColorBrewer_1.1-2
 [5] tools_3.6.2         rgdal_1.4-8         polysat_1.7-4       R6_2.4.1          
 [9] vegan_2.5-6         KernSmooth_2.23-17  spData_0.3.8        DBI_1.1.0          
[13] mgcv_1.8-33         colorspace_1.4-1    permute_0.9-5       raster_3.3-13      
[17] sp_1.4-4            tidyselect_1.1.0    GGally_2.0.0        phangorn_2.5.5    
[21] compiler_3.6.2      expm_0.999-5        scales_1.1.1        mvtnorm_1.1-1      
[25] classInt_0.4-3      quadprog_1.5-8      stringr_1.4.0       digest_0.6.25      
[29] R.utils_2.10.1      dismo_1.1-4         pkgconfig_2.0.3     htmltools_0.5.0    
[33] pegas_0.14          fastmap_1.0.1       rlang_0.4.8         rstudioapi_0.11    
[37] shiny_1.5.0         farver_2.0.3        generics_0.0.2      combinat_0.0-8    
[41] gtools_3.8.2        spdep_1.1-5         dplyr_1.0.2         R.oo_1.24.0        
[45] gdistance_1.3-6     Matrix_1.2-18       Rcpp_1.0.5          munsell_0.5.0      
[49] ape_5.4-1           lifecycle_0.2.0     R.methodsS3_1.8.1   stringi_1.5.3      
[53] MASS_7.3-53         plyr_1.8.6          grid_3.6.2          parallel_3.6.2    
[57] gdata_2.18.0        promises_1.1.1      crayon_1.3.4        deldir_1.0-6      
[61] lattice_0.20-41     splines_3.6.2       pillar_1.4.6        igraph_1.2.6      
[65] boot_1.3-25         seqinr_4.2-4        reshape2_1.4.4      codetools_0.2-16  
[69] fastmatch_1.1-0     LearnBayes_2.15.1   mmod_1.3.3          glue_1.4.2        
[73] calibrate_1.7.7     data.table_1.12.8   vctrs_0.3.4         png_0.1-7          
[77] httpuv_1.5.4        RgoogleMaps_1.4.5.3 gtable_0.3.0        purrr_0.3.4        
[81] reshape_0.8.8       ggplot2_3.3.2       xfun_0.18           mime_0.9          
[85] xtable_1.8-4        genetics_1.3.8.1.2  e1071_1.7-3         coda_0.19-4        
[89] later_1.1.0.1       class_7.3-17        tibble_3.0.3        units_0.6-7        
[93] cluster_2.1.0       ellipsis_0.3.1      gap_1.2.2 }  

Serina

unread,
Oct 6, 2022, 9:14:37 PM10/6/22
to poppr
{
> packageDescription("poppr")
Package: poppr
Type: Package
Title: Genetic Analysis of Populations with Mixed Reproduction
Version: 2.8.6
Authors@R: c(person(c("Zhian", "N."), "Kamvar", role = c("cre", "aut"), email =
        "zka...@gmail.com", comment = c(ORCID = "0000-0003-1458-7108")),
        person(c("Javier", "F."), "Tabima", role = "aut", email =
        "tab...@onid.orst.edu", comment = c(ORCID = "0000-0002-3603-2691")),
        person(c("Sydney", "E."), "Everhart", role = c("ctb", "dtc"), email =
        "ever...@unl.edu", comment = c(ORCID = "0000-0002-5773-1280")),
        person(c("Jonah", "C."), "Brooks", role = "aut", email =
        "broo...@onid.orst.edu"), person(c("Stacy", "A."),
        "Krueger-Hadfield", role = "ctb", email = "krue...@cofc.edu",
        comment = c(ORCID = "0000-0002-7324-7448")), person(c("Erik"),
        "Sotka", role = "ctb", email = "sot...@cofc.edu"), person(c("Brian",
        "J."), "Knaus", role = "ctb", email = "briank...@gmail.com",
        comment = c(ORCID = "0000-0003-1665-4343")), person(c("Patrick",
        "G."), "Meirmans", role = "ctb", email = "p.g.me...@uva.nl",
        comment = c(ORCID = "0000-0002-6395-8107")), person(c("Frédéric",
        "D."), "Chevalier", role = "ctb", email = "fch...@txbiomed.org",
        comment = c(ORCID = "0000-0003-2611-8106")), person(c("Niklaus",
        "J."), "Grünwald", role = "ths", email =
        "grun...@science.oregonstate.edu", comment = c(ORCID =
        "0000-0003-1656-7602")))
Maintainer: Zhian N. Kamvar <zka...@gmail.com>
Encoding: UTF-8
URL: https://grunwaldlab.github.io/poppr, https://github.com/grunwaldlab/poppr,
        https://grunwaldlab.github.io/Population_Genetics_in_R/
Description: Population genetic analyses for hierarchical analysis of partially
        clonal populations built upon the architecture of the 'adegenet'
        package.  Originally described in Kamvar, Tabima, and Grünwald (2014)
        <doi:10.7717/peerj.281> with version 2.0 described in Kamvar, Brooks,
        and Grünwald (2015) <doi:10.3389/fgene.2015.00208>.
MailingList: https://groups.google.com/group/poppr
BugReports: https://github.com/grunwaldlab/poppr/issues
Depends: R (>= 2.15.1), adegenet (>= 2.0.0)
Imports: stats, graphics, grDevices, utils, vegan, ggplot2, phangorn, ape (>=
        3.1-1), igraph (>= 1.0.0), methods, ade4, pegas, polysat, dplyr (>=
        0.4), rlang, boot, shiny, magrittr, progressr
Suggests: testthat, knitr, rmarkdown, poweRlaw, cowplot, RClone
License: GPL-2 | GPL-3
VignetteBuilder: knitr
RoxygenNote: 7.1.0
NeedsCompilation: yes
Packaged: 2020-06-02 00:18:35 UTC; zhian
Author: Zhian N. Kamvar [cre, aut] (<https://orcid.org/0000-0003-1458-7108>),
        Javier F. Tabima [aut] (<https://orcid.org/0000-0002-3603-2691>),
        Sydney E. Everhart [ctb, dtc]
        (<https://orcid.org/0000-0002-5773-1280>), Jonah C. Brooks [aut],
        Stacy A. Krueger-Hadfield [ctb]
        (<https://orcid.org/0000-0002-7324-7448>), Erik Sotka [ctb], Brian J.
        Knaus [ctb] (<https://orcid.org/0000-0003-1665-4343>), Patrick G.
        Meirmans [ctb] (<https://orcid.org/0000-0002-6395-8107>), Frédéric D.
        Chevalier [ctb] (<https://orcid.org/0000-0003-2611-8106>), Niklaus J.
        Grünwald [ths] (<https://orcid.org/0000-0003-1656-7602>)
Repository: CRAN
Date/Publication: 2020-06-02 08:50:13 UTC
Built: R 3.6.2; x86_64-apple-darwin15.6.0; 2020-06-03 07:17:52 UTC; unix

-- File: /Library/Frameworks/R.framework/Versions/3.6/Resources/library/poppr/Meta/package.rds
}

On Thursday, October 6, 2022 at 10:20:16 PM UTC+8 zka...@gmail.com wrote:

Zhian Kamvar

unread,
Oct 7, 2022, 8:05:42 PM10/7/22
to Serina, poppr
Thank you for sharing the session info and the code to reproduce the errors. 

Unfortunately, I am unable to reproduce the errors that you saw with my setup. I will try it on a docker container when I have a better internet connection next week. In the meantime, my recommendation would be to update your R version.

All the best,
Zhian

Reply all
Reply to author
Forward
0 new messages