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

Error in .headerTabix(file,(... #242

Closed
sylestiel opened this issue Sep 16, 2020 · 9 comments
Closed

Error in .headerTabix(file,(... #242

sylestiel opened this issue Sep 16, 2020 · 9 comments
Labels
question Further information is requested

Comments

@sylestiel
Copy link

Hi Tim,

What does the following error message mean? How may I fix it?

FragmentHistogram(object = SH2E16, group.by = 'nucleosome_group', region = 'chr1-1-10000000')
Error in .headerTabix(file, ...) : [internal] bgzf_seek() failed

Thank you!

@sylestiel sylestiel added the question Further information is requested label Sep 16, 2020
@timoast
Copy link
Collaborator

timoast commented Sep 16, 2020

Can you try accessing the same range from the fragment file on the command line using tabix?

tabix <fragment_file> chr1:1-10000000

@sylestiel
Copy link
Author

When I enter the following
tabix '/Volumes/BKUP2/scATAC_data/72020_scATAC/SH2_E165/outs/fragments.tsv.gz' chr1:1-10000000
It prompts for the next line with $

I guess it ran

@timoast
Copy link
Collaborator

timoast commented Sep 16, 2020

If nothing is printed then that means there are no fragments in that region. Can you print the first few lines of the fragment file and show them here? gzip -dc <fragment_file> | head

@sylestiel
Copy link
Author

sylestiel commented Sep 16, 2020

Screen Shot 2020-09-16 at 4 00 02 PM

@timoast
Copy link
Collaborator

timoast commented Sep 16, 2020

It seems like maybe something is wrong with the file index, because tabix isn't returning entries even though you have fragments in the region. How did you create the fragment file and index? I'd suggest decompressing the file, re-compressing with bgzip and then re-indexing with tabix, then run tabix <fragment_file> chr1:1-10000000 and see if it prints the expected lines

@sylestiel
Copy link
Author

The fragment file was generated by someone else who used Cell Ranger for that purpose.
Can you provide the scripts to do so?

@timoast
Copy link
Collaborator

timoast commented Sep 16, 2020

gzip -d <fragments>
bgzip <fragments>
tabix -p bed <fragments>

@sylestiel
Copy link
Author

Okay it appears to have worked in the command line. Going to try it in R. Thanks!!

@sylestiel
Copy link
Author

Awesome. It worked!!!

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

No branches or pull requests

2 participants