{
  "id": 94274,
  "title": "Explicit valence for atom # 5 N, 4, is greater than permitted?",
  "url": "/competitions/champs-scalar-coupling/discussion/94274",
  "author_name": "hengck23",
  "post_date": "2019-06-03T16:45:15.068000",
  "votes": 1,
  "comment_count": 6,
  "views": 0,
  "content": "<p>I find quite a lot of such error when i try to extract features using rdkit. is it normal?</p>",
  "messages": [
    {
      "id": 542285,
      "postDate": "2019-06-03T16:45:15.070Z",
      "content": "<p>I find quite a lot of such error when i try to extract features using rdkit. is it normal?</p>",
      "rawMarkdown": "I find quite a lot of such error when i try to extract features using rdkit. is it normal?",
      "votes": 1
    },
    {
      "id": 542314,
      "postDate": "2019-06-03T17:40:10.440Z",
      "content": "<p>Why is it an error? The electronic configuration of nitrogen is 1s^2 2s^2 2p^3, so in principle there are 5 electrons available for bonding. While I agree that the two 2s electrons may not always participate in the bonding, there's probably a few molecules in those 130.000 molecules that stray away from textbooks rules of thumb :)</p>\n\n<p>Edit : ammonium ions have a valence of 4 : <a href=\"https://en.wikipedia.org/wiki/Ammonium\">https://en.wikipedia.org/wiki/Ammonium</a></p>",
      "rawMarkdown": "Why is it an error? The electronic configuration of nitrogen is 1s^2 2s^2 2p^3, so in principle there are 5 electrons available for bonding. While I agree that the two 2s electrons may not always participate in the bonding, there's probably a few molecules in those 130.000 molecules that stray away from textbooks rules of thumb :)\n\nEdit : ammonium ions have a valence of 4 : https://en.wikipedia.org/wiki/Ammonium",
      "votes": 2
    },
    {
      "id": 549694,
      "postDate": "2019-06-11T00:05:54.210Z",
      "content": "<p>As already written, the error happens when the atom has bonds more than expected valences.</p>\n\n<p>You may suppress the error by following code (be careful that you may not notice other error with this code).\n```</p>\n\n<h1>Disable errors by RDKit occurred in preprocessing data.</h1>\n\n<p>lg = RDLogger.logger()\nlg.setLevel(RDLogger.CRITICAL)\n```</p>",
      "rawMarkdown": "As already written, the error happens when the atom has bonds more than expected valences.\n\nYou may suppress the error by following code (be careful that you may not notice other error with this code).\n```\n# Disable errors by RDKit occurred in preprocessing data.\nlg = RDLogger.logger()\nlg.setLevel(RDLogger.CRITICAL)\n```\n"
    },
    {
      "id": 542722,
      "postDate": "2019-06-04T04:04:09.477Z",
      "content": "<p>i  have problem reading the xyz files provided using standard chemistry python package.  here is another example:</p>\n\n<p><em>*</em> Open Babel Error  in TetStereoToWedgeHash\n  Failed to set stereochemistry as unable to find an available bond</p>\n\n<p>I wonder what i should do  (e.g. modify what parameters ) in order to prevent the error raise by rdkit or open babel.</p>",
      "rawMarkdown": "i  have problem reading the xyz files provided using standard chemistry python package.  here is another example:\n\n*** Open Babel Error  in TetStereoToWedgeHash\n  Failed to set stereochemistry as unable to find an available bond\n\nI wonder what i should do  (e.g. modify what parameters ) in order to prevent the error raise by rdkit or open babel.",
      "replies": [
        {
          "id": 543029,
          "postDate": "2019-06-04T09:26:57.520Z",
          "content": "<p>You can prevent the 'explicit valance..' rdkit error by using <code>Chem.SanitizeMol</code>. You have to exclude the <code>Chem.SanitizeFlags.SANITIZE_PROPERTIES</code> flag. If you are using Jan H. Jensen's xyz2mol script, than take a look at the <code>chiral_stereo_check</code> function.</p>",
          "rawMarkdown": "You can prevent the 'explicit valance..' rdkit error by using `Chem.SanitizeMol`. You have to exclude the `Chem.SanitizeFlags.SANITIZE_PROPERTIES` flag. If you are using Jan H. Jensen's xyz2mol script, than take a look at the `chiral_stereo_check` function.",
          "votes": 1
        }
      ]
    },
    {
      "id": 542599,
      "postDate": "2019-06-04T01:56:20.500Z",
      "content": "<p>R3-N*<em>:</em>* is usually a Lewis base (the lone electron pair is the base) and can often bind electron deficient molecules or ions. The resulting structure could be positively charged if something like H+ is bound or uncharged. R3- could be a combination of several different groups: H, CH3, etc.</p>",
      "rawMarkdown": "R3-N**:** is usually a Lewis base (the lone electron pair is the base) and can often bind electron deficient molecules or ions. The resulting structure could be positively charged if something like H+ is bound or uncharged. R3- could be a combination of several different groups: H, CH3, etc."
    },
    {
      "id": 542340,
      "postDate": "2019-06-03T18:10:42.310Z",
      "rawMarkdown": "",
      "isDeleted": true
    }
  ],
  "comments": [
    {
      "id": 542314,
      "author_name": "Boris D.",
      "author_url": "",
      "post_date": "2019-06-03T17:40:10.440000",
      "content": "<p>Why is it an error? The electronic configuration of nitrogen is 1s^2 2s^2 2p^3, so in principle there are 5 electrons available for bonding. While I agree that the two 2s electrons may not always participate in the bonding, there's probably a few molecules in those 130.000 molecules that stray away from textbooks rules of thumb :)</p>\n\n<p>Edit : ammonium ions have a valence of 4 : <a href=\"https://en.wikipedia.org/wiki/Ammonium\">https://en.wikipedia.org/wiki/Ammonium</a></p>",
      "votes": 2,
      "replies": []
    },
    {
      "id": 549694,
      "author_name": "corochann",
      "author_url": "",
      "post_date": "2019-06-11T00:05:54.210000",
      "content": "<p>As already written, the error happens when the atom has bonds more than expected valences.</p>\n\n<p>You may suppress the error by following code (be careful that you may not notice other error with this code).\n```</p>\n\n<h1>Disable errors by RDKit occurred in preprocessing data.</h1>\n\n<p>lg = RDLogger.logger()\nlg.setLevel(RDLogger.CRITICAL)\n```</p>",
      "votes": 0,
      "replies": []
    },
    {
      "id": 542722,
      "author_name": "hengck23",
      "author_url": "",
      "post_date": "2019-06-04T04:04:09.477000",
      "content": "<p>i  have problem reading the xyz files provided using standard chemistry python package.  here is another example:</p>\n\n<p><em>*</em> Open Babel Error  in TetStereoToWedgeHash\n  Failed to set stereochemistry as unable to find an available bond</p>\n\n<p>I wonder what i should do  (e.g. modify what parameters ) in order to prevent the error raise by rdkit or open babel.</p>",
      "votes": 0,
      "replies": [
        {
          "id": 543029,
          "author_name": "Peter",
          "author_url": "",
          "post_date": "2019-06-04T09:26:57.520000",
          "content": "<p>You can prevent the 'explicit valance..' rdkit error by using <code>Chem.SanitizeMol</code>. You have to exclude the <code>Chem.SanitizeFlags.SANITIZE_PROPERTIES</code> flag. If you are using Jan H. Jensen's xyz2mol script, than take a look at the <code>chiral_stereo_check</code> function.</p>",
          "votes": 1,
          "replies": []
        }
      ]
    },
    {
      "id": 542599,
      "author_name": "Mycroft Holmes",
      "author_url": "",
      "post_date": "2019-06-04T01:56:20.500000",
      "content": "<p>R3-N*<em>:</em>* is usually a Lewis base (the lone electron pair is the base) and can often bind electron deficient molecules or ions. The resulting structure could be positively charged if something like H+ is bound or uncharged. R3- could be a combination of several different groups: H, CH3, etc.</p>",
      "votes": 0,
      "replies": []
    },
    {
      "id": 542340,
      "author_name": "",
      "author_url": "",
      "post_date": "2019-06-03T18:10:42.310000",
      "content": "",
      "votes": 0,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "542285": "I find quite a lot of such error when i try to extract features using rdkit. is it normal?",
    "542314": "Why is it an error? The electronic configuration of nitrogen is 1s^2 2s^2 2p^3, so in principle there are 5 electrons available for bonding. While I agree that the two 2s electrons may not always participate in the bonding, there's probably a few molecules in those 130.000 molecules that stray away from textbooks rules of thumb :)\n\nEdit : ammonium ions have a valence of 4 : https://en.wikipedia.org/wiki/Ammonium",
    "549694": "As already written, the error happens when the atom has bonds more than expected valences.\n\nYou may suppress the error by following code (be careful that you may not notice other error with this code).\n```\n# Disable errors by RDKit occurred in preprocessing data.\nlg = RDLogger.logger()\nlg.setLevel(RDLogger.CRITICAL)\n```\n",
    "542722": "i  have problem reading the xyz files provided using standard chemistry python package.  here is another example:\n\n*** Open Babel Error  in TetStereoToWedgeHash\n  Failed to set stereochemistry as unable to find an available bond\n\nI wonder what i should do  (e.g. modify what parameters ) in order to prevent the error raise by rdkit or open babel.",
    "542599": "R3-N**:** is usually a Lewis base (the lone electron pair is the base) and can often bind electron deficient molecules or ions. The resulting structure could be positively charged if something like H+ is bound or uncharged. R3- could be a combination of several different groups: H, CH3, etc.",
    "542340": ""
  }
}