Commit e4c6d34a authored by knittelf's avatar knittelf
Browse files

clean up

parent 206e9d74
......@@ -9,7 +9,7 @@
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
......@@ -27,7 +27,7 @@
},
{
"cell_type": "code",
"execution_count": 11,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
......@@ -61,7 +61,7 @@
},
{
"cell_type": "code",
"execution_count": 18,
"execution_count": null,
"metadata": {
"scrolled": true
},
......@@ -73,7 +73,7 @@
},
{
"cell_type": "code",
"execution_count": 33,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
......@@ -83,7 +83,7 @@
},
{
"cell_type": "code",
"execution_count": 34,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
......@@ -100,18 +100,9 @@
},
{
"cell_type": "code",
"execution_count": 35,
"execution_count": null,
"metadata": {},
"outputs": [
{
"output_type": "execute_result",
"data": {
"text/plain": "dict_keys(['C', '2H', 'H'])"
},
"metadata": {},
"execution_count": 35
}
],
"outputs": [],
"source": [
"allelems = dict(cc_dict)\n",
"allelems.update(af_dict)\n",
......@@ -120,25 +111,16 @@
},
{
"cell_type": "code",
"execution_count": 37,
"execution_count": null,
"metadata": {},
"outputs": [
{
"output_type": "execute_result",
"data": {
"text/plain": "{'C': 3, '2H': 4, 'H': 1}"
},
"metadata": {},
"execution_count": 37
}
],
"outputs": [],
"source": [
"allelems"
]
},
{
"cell_type": "code",
"execution_count": 41,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
......@@ -160,25 +142,16 @@
},
{
"cell_type": "code",
"execution_count": 43,
"execution_count": null,
"metadata": {},
"outputs": [
{
"output_type": "execute_result",
"data": {
"text/plain": "{'C': 3, '2H': 4, 'H': 1}"
},
"metadata": {},
"execution_count": 43
}
],
"outputs": [],
"source": [
"res"
]
},
{
"cell_type": "code",
"execution_count": 46,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
......@@ -199,69 +172,7 @@
},
{
"cell_type": "code",
"execution_count": 5,
"metadata": {
"scrolled": true
},
"outputs": [
{
"data": {
"text/plain": [
"'C25H44D5N1O9P1'"
]
},
"execution_count": 5,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"#print dictionary in one string to get dbe from LX1.0 tools\n",
"elemental_comp = \"\".join(f\"{key}{value}\" for key, value in res.items())\n",
"#replace 2H with D\n",
"elemental_comp = elemental_comp.replace('2H','D')\n",
"elemental_comp"
]
},
{
"cell_type": "code",
"execution_count": 6,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Enter dbe:2.5\n"
]
}
],
"source": [
"#input dbe\n",
"dbe = input('Enter dbe:')"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {},
"outputs": [],
"source": [
"#calculating dbr according to mfql_tools.py\n",
"#no idea to calculate the dbr correctly when deuterium is present so use output from LX tools\n",
"#if adduct == 'NH4':\n",
"# dbe = res['C'] + 1 - res['H']/2 + res['N']/2 - 2.5 #how is deuterium implemented?, check for other compounds\n",
"#if adduct == 'HCOO' and lipid_class == 'NL':\n",
"# dbe = res['C'] + 1 - res['H']/2 - 2.5\n",
"#if lipid_class == 'Cer':\n",
"# dbe = res['C'] + 1 - res['H']/2 + res['N']/2 - 3.5\n",
"#else:\n",
"# dbe = res['C'] + 1 - res['H']/2 + res['N']/2 - 2 #how is deuterium implemented?, check for other compounds"
]
},
{
"cell_type": "code",
"execution_count": 8,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
......@@ -274,27 +185,7 @@
},
{
"cell_type": "code",
"execution_count": 9,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"'isEven'"
]
},
"execution_count": 9,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"such"
]
},
{
"cell_type": "code",
"execution_count": 10,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
......@@ -353,9 +244,9 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3.7.5 64-bit ('mfql_des': conda)",
"display_name": "Python 3",
"language": "python",
"name": "python37564bitmfqldesconda008f121642b041f890de0d051e241abf"
"name": "python3"
},
"language_info": {
"codemirror_mode": {
......@@ -367,7 +258,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.5-final"
"version": "3.7.6-final"
}
},
"nbformat": 4,
......
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