Open IanSudbery opened 3 years ago
Also main
of bam2peakshape.buildDensityMatricies
has a logging counter called c
:
But if you use a control file and use --use-strand
then this happens:
Meaning that c
is overwritten with a PeakShapeResult object. This means an error is raised next time the counter is updated.
The PeakShapeResult class is defined in
bamtools.peakshape
thus:however, in several places
bam2peakshape.py
refers to the.hist
property of a PeakShapeResult or PeakShapeCounts object. Looking at the code, I'm getting the feeling that what is nowcounts
was once calledhist
, but when it was renamed, not all instances ofhist
were caught.This means that if bam2peakshape is called with the argument
--use-strand
the error:AttributeError: 'PeakShapeResult' object has no attribute 'hist'
will be thrown. The correction should be simple, but this really should also be covered by a test. I would do it now, but I've got a butt load of lectures to write before next week. Maybe I'll get round it later.