sshen82 / BandNorm

Simple Normalization Method for single-cell Hi-C
GNU General Public License v3.0
1 stars 2 forks source link

questions about bandnorm_juicer #10

Closed LHXqwq closed 7 months ago

LHXqwq commented 8 months ago

bandnorm_juicer(path = "/home/lihaoxing/test2/4-192hic", 500000, chroms="1", save = TRUE, save_path = "/home/lihaoxing/test2/band_norm_out") Error in rename(., chrom = chromA, binA = x, binB = y, count = counts) : object 'chromA' not found bandnorm_juicer(path = "/home/lihaoxing/test2/4-192hic", 500000, chroms="all", save = TRUE, save_path = "/home/lihaoxing/test2/band_norm_out") Error: Error finding block data.

Hello, I'm having a problem using the bandnorm_juicer function, but chromosome selection 1 or all can't work properly, is it wrong to use my command?

sshen82 commented 8 months ago

Hi, Thank you for using our package! Indeed, in the line "return(fread(paths[i], select = c(1, 2, 4, 5)) %>% rename(chrom = V1, binA = V2, binB = V4, count = V5) %>%" in my code, the rename function should be dplyr::rename, since there are multiple functions that are called "rename". I just fixed this bug. Feel free to reach out if there are other things you would like to discuss!

Yours sincerely, Siqi Shen

sshen82 commented 8 months ago

I can't see your second question here in Github, but can see that in the email... Your question is that if the format is [binA, binB, count], how to obtain the diag? Well, the diag is just binB - binA. It is telling you the genomic distance for the interaction. Unfortunately, our package doesn't support the HiC-Pro format, but it should be easy to re-write.