Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#Step1-IndexError: tuple index out of range #24

Open
DongshengWu opened this issue Sep 3, 2023 · 6 comments
Open

#Step1-IndexError: tuple index out of range #24

DongshengWu opened this issue Sep 3, 2023 · 6 comments

Comments

@DongshengWu
Copy link

Hello,
I'm receiving an error when running step1 for estimating local genetic covariance and correlation and I wondered if you could help me figure it out?

[INFO] Command issued:
hess.py
--bfile 1kg_eur_1pct/1kg_eur_1pct_chr15
--local-rhog 1.txt 2.txt
--partition EUR/fourier_ls-chr15.bed
--out LC/step1
--chrom 15
[INFO] Loaded 50 partitions on chromosome 15
[INFO] Average window size is 1650395
[INFO] 248416 SNPs read from reference panel
[INFO] Loaded 65093 SNPs with rs IDs and single-letter alleles on chromosome 15 from the GWAS summary data file
[INFO] 54792 SNPs left after filtering
[INFO] Loaded 217307 SNPs with rs IDs and single-letter alleles on chromosome 15 from the GWAS summary data file
[INFO] 175560 SNPs left after filtering
[INFO] Loading fam file 1kg_eur_1pct/1kg_eur_1pct_chr15.fam
[INFO] Loading bim file 1kg_eur_1pct/1kg_eur_1pct_chr15.bim
/Users/wds/opt/anaconda3/envs/hess/lib/python2.7/site-packages/pysnptools/snpreader/snpreader.py:625: FutureWarning: Conversion of the second argument of issubdtype from str to str is deprecated. In future, it will be treated as np.string_ == np.dtype(str).type.
assert np.issubdtype(self._row.dtype, str) and len(self._row.shape)==2 and self._row.shape[1]==2, "iid should be dtype str, have two dimensions, and the second dimension should be size 2"
/Users/wds/opt/anaconda3/envs/hess/lib/python2.7/site-packages/pysnptools/snpreader/snpreader.py:626: FutureWarning: Conversion of the second argument of issubdtype from str to str is deprecated. In future, it will be treated as np.string_ == np.dtype(str).type.
assert np.issubdtype(self._col.dtype, str) and len(self._col.shape)==1, "sid should be of dtype of str and one dimensional"
[INFO] bed file is open 1kg_eur_1pct/1kg_eur_1pct_chr15.bed
[INFO] 1 SNPs in locus chr15:20001200-21131604
Traceback (most recent call last):
File "hess.py", line 217, in
main()
File "hess.py", line 45, in main
argmap['out'])
File "/Users/wds/Desktop/hess/src/estimation.py", line 427, in local_rhog_step1
ld_locus, sumstats1_locus)
File "/Users/wds/Desktop/hess/src/estimation.py", line 79, in local_hsqg_step1_helper
nsnp = ld.shape[0]
IndexError: tuple index out of range

@Zhangzzzzzy
Copy link

Did you find a solution?

@Hao-Gloria
Copy link

When the 'snp' column contains something other than 'rs' identifiers, it results in this error.

@Zhangzzzzzy
Copy link

When the 'snp' column contains something other than 'rs' identifiers, it results in this error.

Okay, thank you very much for your reply.

@Hao-Gloria
Copy link

When the 'snp' column contains something other than 'rs' identifiers, it results in this error.

The deletion of the first row of the reference panel for chromosome 15, in addition to the above, no longer results in an error.

@umbrellaling
Copy link

When the 'snp' column contains something other than 'rs' identifiers, it results in this error.

I have already to remove all the "SNP"column contains something other than "rs", but I still got this problem. I don't know how to deletion of the first row of the reference panel.

@Hao-Gloria
Copy link

When the 'snp' column contains something other than 'rs' identifiers, it results in this error.

I have already to remove all the "SNP"column contains something other than "rs", but I still got this problem. I don't know how to deletion of the first row of the reference panel.

You will need to manually modify the bed files to remove the loci that occur errors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants