Hoping someone may be able to assist me with an error I am encountering with the dartR package.
I recently had to reinstall dartR and since reinstalling the package, the gl.read.dart function is no longer able to read the data file. The code and data inputted has not changed (which worked fine previously) and so I am assuming it's something to do with reinstalling dartR.
This is what I entered:
test.gl <- gl.read.dart(filename = "Report_DMarc21-6505_3_SNP_data.csv", ind.metafile = "animal_metadata.csv")
Which produces the following:
Starting gl.read.dart
Starting utils.read.dart
Topskip not provided.
Setting topskip to 6 .
Reading in the SNP data
Detected 1 row format.
Added the following locus metrics:
AlleleID CloneID AlleleSequence TrimmedSequence SNP SnpPosition CallRate OneRatioRef OneRatioSnp FreqHomRef FreqHomSnp FreqHets PICRef PICSnp AvgPIC AvgCountRef AvgCountSnp RepAvg .
Number of rows per clone (should be only 1 s): 1
Number of rows per clone (should be only 1 s): 2
Error in if (nrows != as.numeric(names(tt)))
{ : the condition has length > 1
Which then stops the function from proceeding.
I have tried running the code on both a MacOS (10.13) and WindowsOS and with the latest version of R (4.2.0) with the same result.
I have followed the dartR installation steps in the tutorial provided and so I am confident that I have installed the package correctly. I also tried installing older versions of the package with the same result.
Is there something else I can try to fix this problem? Any advice would be greatly appreciated!