Entering edit mode
20 months ago
VANSHIKA
•
0
Exception in thread "main" htsjdk.samtools.SAMFormatException: Error parsing SAM header. @RG line missing SM tag. Line:
@RG ID:staralign1; ; Line number 10
at htsjdk.samtools.SAMTextHeaderCodec.reportErrorParsingLine(SAMTextHeaderCodec.java:258)
at htsjdk.samtools.SAMTextHeaderCodec.access$200(SAMTextHeaderCodec.java:46)
at htsjdk.samtools.SAMTextHeaderCodec$ParsedHeaderLine.requireTag(SAMTextHeaderCodec.java:358)
at htsjdk.samtools.SAMTextHeaderCodec.parseRGLine(SAMTextHeaderCodec.java:168)
at htsjdk.samtools.SAMTextHeaderCodec.decode(SAMTextHeaderCodec.java:110)
at htsjdk.samtools.SAMTextReader.readHeader(SAMTextReader.java:216)
at htsjdk.samtools.SAMTextReader.<init>(SAMTextReader.java:63)
at htsjdk.samtools.SAMTextReader.<init>(SAMTextReader.java:73)
at htsjdk.samtools.SamReaderFactory$SamReaderFactoryImpl.open(SamReaderFactory.java:444)
at htsjdk.samtools.SamReaderFactory$SamReaderFactoryImpl.open(SamReaderFactory.java:209)
at picard.sam.SortSam.doWork(SortSam.java:154)
at picard.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:308)
at picard.cmdline.PicardCommandLine.instanceMain(PicardCommandLine.java:103)
at picard.cmdline.PicardCommandLine.main(PicardCommandLine.java:113)
Hi VANSHIKA,
welcome.
it might be good to add some more info on your "question". Now it only shows an error message which, without context, is rather meaningless.
What exactly are you stuck on? what are you trying to achieve? The "error" already gives you an indication what might go wrong, did you look into that?
i think picard is expecting read groups. you may need to add them: https://gatk.broadinstitute.org/hc/en-us/articles/360037226472-AddOrReplaceReadGroups-Picard-
It looks like RG lines are present, it just needs sample name in the line.