genenetwork / genenetwork2

GeneNetwork (2nd generation)
http://gn2.genenetwork.org/
GNU Affero General Public License v3.0
34 stars 24 forks source link

CSV format data download incorrectly formatted. #822

Open rupertoverall opened 7 months ago

rupertoverall commented 7 months ago

A minor point, but the download buttons on trait pages (as in the attached screenshot ) offer CSV format and a helpful line of R code to read them in. The code will introduce errors though as the 6 header lines are not commented.

Best solution is to add '#' comments to the header lines (as suggested by the R and python code snippets).

Screenshot 2023-12-12 at 14 51 41
ZulfiiaDitto commented 1 month ago

@rupertoverall, As a suggestion you can utilize the following script

import pandas as pd trait = pd.read_csv('0026392353.csv', skiprows=7)

trait <- read.csv('10025905738.csv',skip = 7)

rupertoverall commented 1 month ago

@ZulfiiaDitto Yes - this what I have also been doing as a workaround. My comment was rather to the developers that this information should be included in the examples on the webpage. Commented-out lines are much friendlier to automated workflows.