def updateELevel2(dFN, dForm, wigDir): '''Dont need to do it by chromosome because it is small enough''' '''Also dont need to flip the strand because the wig is opposite as well''' NX = Nexus(dFN, dForm) NX.load(['tcc', 'eLevel']) wigDict = cgWig.loadWigDictFloat(wigDir) while NX.nextID(): coord_value = cgWig.getExpressionProfile(NX.tcc, wigDict) NX.eLevel = max(coord_value.values()) NX.save()
def updateELevel2(dFN, dForm, wigDir): '''Dont need to do it by chromosome because it is small enough''' '''Also dont need to flip the strand because the wig is opposite as well''' NX = Nexus(dFN, dForm) NX.load(['tcc', 'eLevel']) wigDict = cgWig.loadWigDictFloat(wigDir) while NX.nextID(): coord_value = cgWig.getExpressionProfile(NX.tcc, wigDict) NX.eLevel = max(coord_value.values()) NX.save()