Commit 25860ed2 authored by Yan's avatar Yan

Setup now includes extra_require

* rawautoparams 0.0.2 now supported
* fixed headers order
* version increased to 0.0.14
parent dec50bbd
......@@ -213,7 +213,7 @@ def about(parent):
QtWidgets.QMessageBox.information(
parent, "About Prasopes",
"Prasopes Finnigan raw file viewer\n\n"
"Version: 0.0.13 (alpha)")
"Version: 0.0.14 (alpha)")
def main():
......
......@@ -434,17 +434,22 @@ def legendize(rawlegend, chrom_data):
else:
text = "{}ms^{} {:.2f}@{:.1f}V; m/z = {:.1f}-{:.1f}".format(
marks[int(wut[0])], *wut[1:])
elif chrom_data['machtype'] == 57:
if int(wut[0]) == 1:
text = "ms; m/z = {:.1f}-{:.1f}".format(*wut[1:])
elif chrom_data['machtype'] in (57, 63):
if int(wut[1]) == 1:
text = "{}ms; m/z = {:.1f}-{:.1f}".format(
marks[int(wut[0])], *wut[2:])
else:
text = ("ms^{:.0f};"+"".join([" {:.2f}/{:.1f}@{:.1f}V" for _ in
range(int(wut[0])-1)])+"; m/z = {:.1f}-{:.1f}").format(
*wut)
text = ("{}ms^{:.0f};" + "".join([" {:.2f}/{:.1f}@{:.1f}V" for
_ in range(int(wut[1])-1)]) +
"; m/z = {:.1f}-{:.1f}").format(
marks[int(wut[0])], *wut[1:])
else:
text = "unknown header type"
return text
strdata = [translate(i) for i in np.unique(np.array(rawlegend), axis=0)]
uniqindexs = np.unique(np.array(rawlegend), return_index=True)\
if np.array(rawlegend).dtype == np.dtype('O') else\
np.unique(np.array(rawlegend), axis=0, return_index=True)
strdata = [translate(i) for i in rawlegend[np.sort(uniqindexs[1])]]
strtext = " and\n".join(strdata) + "; t = {:.2f}-{:.2f} min".format(
chrom_data['t_start'], chrom_data['t_end'])
return strtext
......
......@@ -5,7 +5,7 @@ with open("README.md", "r") as fh:
setup(
name="prasopes",
version="0.0.13",
version="0.0.14",
author="Jan Zelenka",
author_email="3yanyanyan@gmail.com",
description="Thermo/Finnigan .raw file viewer based on rawprasslib",
......@@ -27,6 +27,8 @@ setup(
'PyQt5-sip;platform_system=="Darwin"',
'matplotlib>=3.0.0',
'rawprasslib>=0.0.4'],
extras_require={
'raw parameters readout': ['rawautoparams>=0.0.2']},
entry_points={
'console_scripts': [
'prasopes = prasopes.__main__:main'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment