python - Renaming series in pandas -


i working series, , wondering how can rename series when writing file. example, output csv consists of following:

gene_name,0 a2ml1,15 aak1,8 

i want following:

gene_name,count a2ml1,15 aak1,8 

note: don't want header "gene_name,0" "gene_name,count." how can accomplish this?

to make "count" name of series, set your_series.name = "count" , call to_csv this: your_series.to_csv("c:\\output.csv", header=true, index_label="gene_name").


Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

javascript - Clean way to programmatically use CSS transitions from JS? -

android - send complex objects as post php java -