Skip to content

Pandas.DataFrame.to_csv() unexpected argument sparsify #12

@kwkroll32

Description

@kwkroll32

Received an error writing vcf output. Apparently pandas.DataFrame.to_csv() doesn't accept the "sparsify" argument (anymore?). Not sure what it is supposed to do, but commenting it out stops the error and still produces a vcf file. If we can't remember where this came from, I propose we remove that argument from this particular to_csv call.

Pandas 0.19.1
See the offending line in output.VCF here

Traceback (most recent call last):
  File "/home/karl/Tools/mucor/mucor.py", line 699, in 
    main()
  File "/home/karl/Tools/mucor/mucor.py", line 690, in main
    printOutput(config, str(config.outputDir), varDF)
  File "/home/karl/Tools/mucor/mucor.py", line 649, in printOutput
    ow.write(varDF,format,outputDirName,config)
  File "/home/karl/Tools/mucor/output.py", line 95, in write
    self.supported_formats[format]()
  File "/home/karl/Tools/mucor/output.py", line 399, in VCF
    out.to_csv(ofVariantVCF, sep='\t', na_rep='?', index=False, header=True, sparsify=False)
TypeError: to_csv() got an unexpected keyword argument 'sparsify'

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions