Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in write.table #18

Open
dridk opened this issue Aug 24, 2021 · 1 comment · May be fixed by #22
Open

Error in write.table #18

dridk opened this issue Aug 24, 2021 · 1 comment · May be fixed by #22
Assignees
Labels
bug Something isn't working
Milestone

Comments

@dridk
Copy link

dridk commented Aug 24, 2021

Hi,

I m using the docker version of scramble.
I get the following error when I ran this command on my clusters file.

/bin/SCRAMble.R 
--out-name ${PWD}/test 
--cluster-file ${PWD}/MEN_CGH200860-I.sorted.clusters.txt 
--install-dir /app/cluster_analysis/bin/ 
--mei-refs /app/cluster_analysis/resources/MEI_consensus_seqs.fa 
--ref /app/validation/test.fa 
--eval-meis
Done analyzing MEIs
Writing VCF file to /data/share/genmol/sacha/projects/ALU/test.vcf...
Error in write.table(fixed, paste0(outFilePrefix, ".vcf"), row.names = F,  :
  unimplemented type 'list' in 'EncodeElement'
Execution halted

Seems the fixed dataframe contains list for the REF columns. Here is the output of print(fixed) and print(str(fixed) :

print(fixed)

   #CHROM       POS     ID  REF          ALT      QUAL FILTER
11  chr13  18212144 INS:ME NULL <INS:ME:ALU>  79.24415   PASS
10  chr13  38878403 INS:ME NULL <INS:ME:ALU>  60.81471   PASS
9   chr14  57041288 INS:ME NULL <INS:ME:ALU>  78.32513   PASS
8   chr15  40808120 INS:ME NULL <INS:ME:ALU>  73.71777   PASS
7   chr16  89224981 INS:ME NULL <INS:ME:ALU>  78.32513   PASS
3    chr2  97185492 INS:ME NULL  <INS:ME:L1>  57.59200   PASS
4    chr2 102706037 INS:ME NULL  <INS:ME:L1>  62.65276   PASS
6   chr22  23928275 INS:ME NULL <INS:ME:ALU> 103.66561   PASS
5   chr22  43928709 INS:ME NULL  <INS:ME:L1>  96.75457   PASS
2    chr4 185440770 INS:ME NULL <INS:ME:ALU>  86.15520   PASS
1    chr5  62561291 INS:ME NULL <INS:ME:ALU> 103.66561   PASS
                                                   INFO
11   MEINFO=chr13:18212144_ALU_Plus,18212144,18212145,+
10   MEINFO=chr13:38878403_ALU_Plus,38878403,38878404,+
9    MEINFO=chr14:57041288_ALU_Plus,57041288,57041289,+
8   MEINFO=chr15:40808120_ALU_Minus,40808120,40808121,-
7    MEINFO=chr16:89224981_ALU_Plus,89224981,89224982,+
3      MEINFO=chr2:97185492_L1_Plus,97185492,97185493,+
4   MEINFO=chr2:102706037_L1_Plus,102706037,102706038,+
6    MEINFO=chr22:23928275_ALU_Plus,23928275,23928276,+
5    MEINFO=chr22:43928709_L1_Minus,43928709,43928710,-
2  MEINFO=chr4:185440770_ALU_Plus,185440770,185440771,+
1     MEINFO=chr5:62561291_ALU_Plus,62561291,62561292,+

print(str(fixed))

'data.frame':   11 obs. of  8 variables:
 $ #CHROM: chr  "chr13" "chr13" "chr14" "chr15" ...
 $ POS   : int  18212144 38878403 57041288 40808120 89224981 97185492 102706037 23928275 43928709 185440770 ...
 $ ID    : chr  "INS:ME" "INS:ME" "INS:ME" "INS:ME" ...
 $ REF   :List of 11
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
  ..$ : NULL
 $ ALT   : chr  "<INS:ME:ALU>" "<INS:ME:ALU>" "<INS:ME:ALU>" "<INS:ME:ALU>" ...
 $ QUAL  : num  79.2 60.8 78.3 73.7 78.3 ...
 $ FILTER: chr  "PASS" "PASS" "PASS" "PASS" ...
 $ INFO  : chr  "MEINFO=chr13:18212144_ALU_Plus,18212144,18212145,+" "MEINFO=chr13:38878403_ALU_Plus,38878403,38878404,+" "MEINFO=chr14:57041288_ALU_Plus,57041288,57041289,+" "MEINFO=chr15:40808120_ALU_Minus,40808120,40808121,-" ...

First list of my cluster file

chr1:931134     right   6       gtgcccccccccccccccccccccgggccaccggttgggtggggagggg       tgggacgtgaacatctctttccgagaggcgtcctgcaggtaggagccgtgctgtgcgtgcataagagggggccgtgactcccc
chr1:939446     left    6       tgctccttgtgttggcccggtagcgcctctaccacctggg        cctccccagccacggtgaggacccaccctggcatgatctcccctcatcacctccccagccacatgtactcggccattcctgttgctga
chr1:955902     right   9       atgccccccaccccgcgtaacagcgggaatacatttgcaccaataaaaaaaacaaaatatgtagaaatccaaaaatgt  ctctgttgccatgtctctgtcctagccacaaggcctctggcttctcctgtgtgtggtcccgacccaccttccaccctacccccc
chr1:971019     right   10      ggggggggggggggggggggggggggggggggggggggggggg     gctggctttaccacctggagaagcagacggccctcctcggggggccgcggcgctgccactcggcacccccacaggtcagtgccgggg
chr1:1046488    right   10      cgccccccccccccggggccccccccaaacccccacaaccccaaccccccacccccc       ccagcactcacccgacatctgcctccgtgactgtgaccaccccagggctcctcctgagccaggcactgccggcccccccc
chr1:1046501    right   8       aggcgccccccaagaccccacccacccccacccccccaccccccacaaagcgaacgcggaccacaaaca   cccgacatctgcctccgtgactgtgaccaccccagggctcctcctgagccaggcactgccggcccccccccgcgcccaccccc
chr1:1048421    left    6       tgtggccgtttttgttagtgggtatgggttccccccgcctttggtggggggggcggccgccggggggggccatgtttg  ggggggggggctaagccaccatcaggctttgagttgggggcaggagcccggattaaggcggggtttcggccagatgcggtggc
chr1:1049076    left    5       gggggtattgtatttctggttttgggggttttttttgggcggggtgctgctcgggggggggggggggggcg ggggcgggggcagctcaggtgggcggggagggg
chr1:1050063    left    17      tgttttggggggggccccggggggggttggggccactttggccctccggggggggggggggggggctgggggggg     gggggggggggggggttgaacgtttgggcgggtacaggttccaggtagcattgcagttaggatgcggctcagtctagtctgggttttgag
chr1:1050070    left    6       cggggcggggccccgggggggggtggggcccctttcgcccccccggggggggggggggggctcgggggggggggggtt  ggggggggttgaacgtttgggcgggtacaggttccaggtagcattgcagttaggatgcggctcagtctagtctgggttttgag

@rebeccaito
Copy link
Contributor

Thanks for this issue. We should return "N" instead of NULL when there is missing reference/alt information to keep the VCF formatted correctly.

I see that you're using the test.fa as input, but your data was aligned to a different reference. test.fa is not meant to be used on real data. Please use the original fasta reference that your sample was aligned to (for example, hg19.fa).

@rebeccaito rebeccaito self-assigned this Feb 11, 2022
@rebeccaito rebeccaito added the bug Something isn't working label Feb 11, 2022
@rebeccaito rebeccaito added this to the 2022.0 milestone Feb 11, 2022
@rebeccaito rebeccaito linked a pull request Feb 11, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants