Closed nievergeltlab closed 9 years ago
I ran the following command:
python ldsc.py --h2 mydata.sumstats --ref-ld-chr eur_w_ld_chr/ --w-ld-chr eur_w_ld_chr/ --out myresults_ldsc
And got the following error:
Traceback (most recent call last): File "ldsc.py", line 617, in sumstats.estimate_h2(args, log) File "/home/genetics/Desktop/ptsd_analysis_10/ldsc/ldscore/sumstats.py", line 258, in estimate_h2 args, log, args.h2) File "/home/genetics/Desktop/ptsd_analysis_10/ldsc/ldscore/sumstats.py", line 234, in _read_ld_sumstats sumstats = _read_sumstats(args, log, fh, alleles=alleles, dropna=dropna) File "/home/genetics/Desktop/ptsd_analysis_10/ldsc/ldscore/sumstats.py", line 165, in _read_sumstats sumstats = sumstats.drop_duplicates(subset='SNP') TypeError: drop_duplicates() got an unexpected keyword argument 'subset'
Any advice? Thanks
I think this means you're using an old version of pandas. From the command line, try pip install --upgrade pandas and see if that helps.
pandas
pip install --upgrade pandas
It worked. Thank you very much
I ran the following command:
python ldsc.py --h2 mydata.sumstats --ref-ld-chr eur_w_ld_chr/ --w-ld-chr eur_w_ld_chr/ --out myresults_ldsc
And got the following error:
Traceback (most recent call last): File "ldsc.py", line 617, in
sumstats.estimate_h2(args, log)
File "/home/genetics/Desktop/ptsd_analysis_10/ldsc/ldscore/sumstats.py", line 258, in estimate_h2
args, log, args.h2)
File "/home/genetics/Desktop/ptsd_analysis_10/ldsc/ldscore/sumstats.py", line 234, in _read_ld_sumstats
sumstats = _read_sumstats(args, log, fh, alleles=alleles, dropna=dropna)
File "/home/genetics/Desktop/ptsd_analysis_10/ldsc/ldscore/sumstats.py", line 165, in _read_sumstats
sumstats = sumstats.drop_duplicates(subset='SNP')
TypeError: drop_duplicates() got an unexpected keyword argument 'subset'
Any advice? Thanks