You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to load the hic matrices which I have binned at 20kb resolution (N*M matrix, with approraite row and column names as described in input format for TXT matrices)
hifive workded fine till the creation of fend object file from the chromosomes lengths file using the follwing commands:
import hifive
fend = hifive.Fend(fend.object, mode='w', binned=20000)
fend.load_bins(chrom_length_filename, genome_name='MM10', format='len')
fend.save()
But next when I run,
data = hifive.HiCData(out_filename, mode='w')
data.load_data_from_matrices(fend.object, ['chr1.matrix', 'chr2.matrix', 'chr1_by_chr2.matrix']), I get error: AttributeError: 'HiCData' object has no attribute 'load_data_from_matrices'
I also tried to run in directly from linux shell, where I am able to generate the binned fend file using the chromosome lengths, But got an error when I tried to load the hic data from matrices to create the HiC-data object.
AttributeError: 'HiCData' object has no attribute 'fends'
Typing data.load_binned_data_from_matrices inside python appears to be something....So I used it as follows:
data = hifive.HiCData(out_filename, mode='w') data.load_binned_data_from_matrices(fend.object, ['chr1.matrix', 'chr2.matrix', 'chr1_by_chr2.matrix'])
but this throws another error: AttributeError: 'list' object has no attribute 'split''
which is probably originating from near 785 in script hic_data.py.
Regarding the missing fend file from your first post, you need to include the fend filename in the path given on the command line.
As for the other error, I appreciate you catching this error in the documentation. If you look at the specific requirement of the 'filename' argument of 'load_binned_data_from_matices', if text files at being passed, you need to use an expression with a wildcard matching all desired text matrix files, such as 'chr*.txt' The indication to use a comma-separated list in the function description is incorrect and will be updated.
Please let me know if this doesn't solve the issue for you.
Thanks!
I am facing to related (possibly) issues:
I am trying to load the hic matrices which I have binned at 20kb resolution (N*M matrix, with approraite row and column names as described in input format for TXT matrices)
hifive workded fine till the creation of fend object file from the chromosomes lengths file using the follwing commands:
import hifive
fend = hifive.Fend(fend.object, mode='w', binned=20000)
fend.load_bins(chrom_length_filename, genome_name='MM10', format='len')
fend.save()
But next when I run,
data = hifive.HiCData(out_filename, mode='w')
data.load_data_from_matrices(fend.object, ['chr1.matrix', 'chr2.matrix', 'chr1_by_chr2.matrix']), I get error:
AttributeError: 'HiCData' object has no attribute 'load_data_from_matrices'
I also tried to run in directly from linux shell, where I am able to generate the binned fend file using the chromosome lengths, But got an error when I tried to load the hic data from matrices to create the HiC-data object.
AttributeError: 'HiCData' object has no attribute 'fends'
This was generated from the following command
hifive hic-data -X /path/to/matrices.txt path/to/fend/ path/to/output.
Can you please help me regarding these issues. I am using the latest (1.5) version of hifive which I installed using pip with python 2.7.11
Thank you.
The text was updated successfully, but these errors were encountered: