| 0 | 1 <html> | 
|  | 2 <head> | 
|  | 3 <title>MayaChemTools:Documentation:SDFileUtil.pm</title> | 
|  | 4 <meta http-equiv="content-type" content="text/html;charset=utf-8"> | 
|  | 5 <link rel="stylesheet" type="text/css" href="../../css/MayaChemTools.css"> | 
|  | 6 </head> | 
|  | 7 <body leftmargin="20" rightmargin="20" topmargin="10" bottommargin="10"> | 
|  | 8 <br/> | 
|  | 9 <center> | 
|  | 10 <a href="http://www.mayachemtools.org" title="MayaChemTools Home"><img src="../../images/MayaChemToolsLogo.gif" border="0" alt="MayaChemTools"></a> | 
|  | 11 </center> | 
|  | 12 <br/> | 
|  | 13 <div class="DocNav"> | 
|  | 14 <table width="100%" border=0 cellpadding=0 cellspacing=2> | 
|  | 15 <tr align="left" valign="top"><td width="33%" align="left"><a href="./PseudoHeap.html" title="PseudoHeap.html">Previous</a>  <a href="./index.html" title="Table of Contents">TOC</a>  <a href="./SequenceFileUtil.html" title="SequenceFileUtil.html">Next</a></td><td width="34%" align="middle"><strong>SDFileUtil.pm</strong></td><td width="33%" align="right"><a href="././code/SDFileUtil.html" title="View source code">Code</a> | <a href="./../pdf/SDFileUtil.pdf" title="PDF US Letter Size">PDF</a> | <a href="./../pdfgreen/SDFileUtil.pdf" title="PDF US Letter Size with narrow margins: www.changethemargins.com">PDFGreen</a> | <a href="./../pdfa4/SDFileUtil.pdf" title="PDF A4 Size">PDFA4</a> | <a href="./../pdfa4green/SDFileUtil.pdf" title="PDF A4 Size with narrow margins: www.changethemargins.com">PDFA4Green</a></td></tr> | 
|  | 16 </table> | 
|  | 17 </div> | 
|  | 18 <p> | 
|  | 19 </p> | 
|  | 20 <h2>NAME</h2> | 
|  | 21 <p>SDFileUtil</p> | 
|  | 22 <p> | 
|  | 23 </p> | 
|  | 24 <h2>SYNOPSIS</h2> | 
|  | 25 <p>use SDFileUtil ;</p> | 
|  | 26 <p>use SDFileUtil qw(:all);</p> | 
|  | 27 <p> | 
|  | 28 </p> | 
|  | 29 <h2>DESCRIPTION</h2> | 
|  | 30 <p><strong>SDFileUtil</strong> module provides the following functions:</p> | 
|  | 31 <p> <a href="#generatecmpdatomaliaspropertylines">GenerateCmpdAtomAliasPropertyLines</a>, <a href="#generatecmpdatomline">GenerateCmpdAtomLine</a>, <a href="#generatecmpdbondline">GenerateCmpdBondLine</a> | 
|  | 32 , <a href="#generatecmpdchargepropertylines">GenerateCmpdChargePropertyLines</a>, <a href="#generatecmpdcommentsline">GenerateCmpdCommentsLine</a>, <a href="#generatecmpdcountsline">GenerateCmpdCountsLine</a> | 
|  | 33 , <a href="#generatecmpddataheaderlabelsandvalueslines">GenerateCmpdDataHeaderLabelsAndValuesLines</a>, <a href="#generatecmpdisotopepropertylines">GenerateCmpdIsotopePropertyLines</a> | 
|  | 34 , <a href="#generatecmpdmiscinfoline">GenerateCmpdMiscInfoLine</a>, <a href="#generatecmpdmolnameline">GenerateCmpdMolNameLine</a> | 
|  | 35 , <a href="#generatecmpdradicalpropertylines">GenerateCmpdRadicalPropertyLines</a>, <a href="#generateemptyctabblocklines">GenerateEmptyCtabBlockLines</a> | 
|  | 36 , <a href="#generatemisclinedatestamp">GenerateMiscLineDateStamp</a>, <a href="#getallandcommoncmpddataheaderlabels">GetAllAndCommonCmpdDataHeaderLabels</a> | 
|  | 37 , <a href="#getcmpddataheaderlabels">GetCmpdDataHeaderLabels</a>, <a href="#getcmpddataheaderlabelsandvalues">GetCmpdDataHeaderLabelsAndValues</a>, <a href="#getcmpdfragments">GetCmpdFragments</a> | 
|  | 38 , <a href="#getctablinescount">GetCtabLinesCount</a>, <a href="#getinvalidatomnumbers">GetInvalidAtomNumbers</a>, <a href="#getunknownatoms">GetUnknownAtoms</a> | 
|  | 39 , <a href="#internalbondordertomdlbondtype">InternalBondOrderToMDLBondType</a>, <a href="#internalbondstereochemistrytomdlbondstereo">InternalBondStereochemistryToMDLBondStereo</a> | 
|  | 40 , <a href="#internalchargetomdlcharge">InternalChargeToMDLCharge</a>, <a href="#internalspinmultiplicitytomdlradical">InternalSpinMultiplicityToMDLRadical</a>, <a href="#iscmpd2d">IsCmpd2D</a> | 
|  | 41 , <a href="#iscmpd3d">IsCmpd3D</a>, <a href="#mdlbondstereotointernalbondstereochemistry">MDLBondStereoToInternalBondStereochemistry</a> | 
|  | 42 , <a href="#mdlbondtypetointernalbondorder">MDLBondTypeToInternalBondOrder</a>, <a href="#mdlchargetointernalcharge">MDLChargeToInternalCharge</a> | 
|  | 43 , <a href="#mdlradicaltointernalspinmultiplicity">MDLRadicalToInternalSpinMultiplicity</a>, <a href="#parsecmpdatomaliaspropertyline">ParseCmpdAtomAliasPropertyLine</a> | 
|  | 44 , <a href="#parsecmpdatomline">ParseCmpdAtomLine</a>, <a href="#parsecmpdbondline">ParseCmpdBondLine</a>, <a href="#parsecmpdchargepropertyline">ParseCmpdChargePropertyLine</a> | 
|  | 45 , <a href="#parsecmpdcommentsline">ParseCmpdCommentsLine</a>, <a href="#parsecmpdcountsline">ParseCmpdCountsLine</a>, <a href="#parsecmpdisotopepropertyline">ParseCmpdIsotopePropertyLine</a> | 
|  | 46 , <a href="#parsecmpdmiscinfoline">ParseCmpdMiscInfoLine</a>, <a href="#parsecmpdmolnameline">ParseCmpdMolNameLine</a>, <a href="#parsecmpdradicalpropertyline">ParseCmpdRadicalPropertyLine</a> | 
|  | 47 , <a href="#readcmpdstring">ReadCmpdString</a>, <a href="#removecmpddataheaderlabelandvalue">RemoveCmpdDataHeaderLabelAndValue</a>, <a href="#washcmpd">WashCmpd</a> | 
|  | 48 </p><p> | 
|  | 49 </p> | 
|  | 50 <h2>METHODS</h2> | 
|  | 51 <dl> | 
|  | 52 <dt><strong><a name="generatecmpdatomaliaspropertylines" class="item"><strong>GenerateCmpdAtomAliasPropertyLines</strong></a></strong></dt> | 
|  | 53 <dd> | 
|  | 54 <div class="OptionsBox"> | 
|  | 55     @Lines = GenerateCmpdAtomAliasPropertyLines($AliasValuePairsRef);</div> | 
|  | 56 <p>Returns a formatted atom alias property lines corresponding to successive pairs | 
|  | 57 of atom number and alias values specified by a refernce to an array. Two lines | 
|  | 58 are generate for each atom number and alias value pairs: First line - A  <AtomNum>; | 
|  | 59 Second line:<AtomAlias>.</p> | 
|  | 60 </dd> | 
|  | 61 <dt><strong><a name="generatecmpdatomline" class="item"><strong>GenerateCmpdAtomLine</strong></a></strong></dt> | 
|  | 62 <dd> | 
|  | 63 <div class="OptionsBox"> | 
|  | 64     $Line = GenerateCmpdAtomLine($AtomSymbol, $AtomX, $AtomY, | 
|  | 65             $AtomZ, [$MassDifference, $Charge, $StereoParity]);</div> | 
|  | 66 <p>Returns a formatted atom data line containing all the input values.</p> | 
|  | 67 </dd> | 
|  | 68 <dt><strong><a name="generatecmpdbondline" class="item"><strong>GenerateCmpdBondLine</strong></a></strong></dt> | 
|  | 69 <dd> | 
|  | 70 <div class="OptionsBox"> | 
|  | 71     $Line = GenerateCmpdBondLine($FirstAtomNum, $SecondAtomNum, | 
|  | 72             $BondType, [$BondStereo]);</div> | 
|  | 73 <p>Returns a formatted bond data line containing all the input values.</p> | 
|  | 74 </dd> | 
|  | 75 <dt><strong><a name="generatecmpdchargepropertylines" class="item"><strong>GenerateCmpdChargePropertyLines</strong></a></strong></dt> | 
|  | 76 <dd> | 
|  | 77 <div class="OptionsBox"> | 
|  | 78     @Lines = GenerateCmpdChargePropertyLines($ChargeValuePairsRef);</div> | 
|  | 79 <p>Returns a formatted M  CHG property lines corresponding to successive pairs of | 
|  | 80 atom number and charge values specified by a refernce to an array.</p> | 
|  | 81 </dd> | 
|  | 82 <dt><strong><a name="generatecmpdcommentsline" class="item"><strong>GenerateCmpdCommentsLine</strong></a></strong></dt> | 
|  | 83 <dd> | 
|  | 84 <div class="OptionsBox"> | 
|  | 85     $Line = GenerateCmpdCommentsLine($Comments);</div> | 
|  | 86 <p>Returns a formatted comments data line.</p> | 
|  | 87 </dd> | 
|  | 88 <dt><strong><a name="generatecmpdcountsline" class="item"><strong>GenerateCmpdCountsLine</strong></a></strong></dt> | 
|  | 89 <dd> | 
|  | 90 <div class="OptionsBox"> | 
|  | 91     $Line = GenerateCmpdCountsLine($AtomCount, $BondCount, | 
|  | 92             $ChiralFlag, [$PropertyCount, $Version]);</div> | 
|  | 93 <p>Returns a formatted line containing all the input values. The default values of 999 | 
|  | 94 and  V2000 are used for <em>PropertyCount</em> and <em>Version</em>.</p> | 
|  | 95 </dd> | 
|  | 96 <dt><strong><a name="generatecmpddataheaderlabelsandvalueslines" class="item"><strong>GenerateCmpdDataHeaderLabelsAndValuesLines</strong></a></strong></dt> | 
|  | 97 <dd> | 
|  | 98 <div class="OptionsBox"> | 
|  | 99     @Lines = GenerateCmpdDataHeaderLabelsAndValuesLines( | 
|  | 100              $DataHeaderLabelsRef, $DataHeaderLabelsAndValuesRef, | 
|  | 101              [$SortDataLabels]);</div> | 
|  | 102 <p>Returns formatted data lines containing header label and values lines corresponding to | 
|  | 103 all data header labels in array reference <em>DataHeaderLabelsRef</em> with values in hash | 
|  | 104 reference <em>DataHeaderLabelsAndValuesRef</em>. By default, data header labels are | 
|  | 105 not sorted and correspond to the label order in array reference <em>DataHeaderLabelsRef</em>.</p> | 
|  | 106 </dd> | 
|  | 107 <dt><strong><a name="generatecmpdisotopepropertylines" class="item"><strong>GenerateCmpdIsotopePropertyLines</strong></a></strong></dt> | 
|  | 108 <dd> | 
|  | 109 <div class="OptionsBox"> | 
|  | 110     @Lines = GenerateCmpdIsotopePropertyLines($IsotopeValuePairsRef);</div> | 
|  | 111 <p>Returns a formatted M ISO property lines corresponding to successive pairs of | 
|  | 112 atom number and isotope values specified by a refernce to an array.</p> | 
|  | 113 </dd> | 
|  | 114 <dt><strong><a name="generatecmpdmiscinfoline" class="item"><strong>GenerateCmpdMiscInfoLine</strong></a></strong></dt> | 
|  | 115 <dd> | 
|  | 116 <div class="OptionsBox"> | 
|  | 117     $Line = GenerateCmpdMiscInfoLine([$ProgramName, $UserInitial, | 
|  | 118             $Code]);</div> | 
|  | 119 <p>Returns a formatted line containing specified user initial, program name, date and code. | 
|  | 120 Default values are: <em>ProgramName - MayaChem; UserInitial - NULL; Code - 2D</em>.</p> | 
|  | 121 </dd> | 
|  | 122 <dt><strong><a name="generatecmpdmolnameline" class="item"><strong>GenerateCmpdMolNameLine</strong></a></strong></dt> | 
|  | 123 <dd> | 
|  | 124 <div class="OptionsBox"> | 
|  | 125     $Line = GenerateCmpdMolNameLine($MolName);</div> | 
|  | 126 <p>Returns a formatted molecule name data line.</p> | 
|  | 127 </dd> | 
|  | 128 <dt><strong><a name="generatecmpdradicalpropertylines" class="item"><strong>GenerateCmpdRadicalPropertyLines</strong></a></strong></dt> | 
|  | 129 <dd> | 
|  | 130 <div class="OptionsBox"> | 
|  | 131     @Lines = GenerateCmpdRadicalPropertyLines($RadicalValuePairsRef);</div> | 
|  | 132 <p>Returns a formatted M  CHG property lines corresponding to successive pairs of | 
|  | 133 atom number and multiplicity values specified by a refernce to an array.</p> | 
|  | 134 </dd> | 
|  | 135 <dt><strong><a name="generateemptyctabblocklines" class="item"><strong>GenerateEmptyCtabBlockLines</strong></a></strong></dt> | 
|  | 136 <dd> | 
|  | 137 <div class="OptionsBox"> | 
|  | 138     $Lines = GenerateCmpdMiscInfoLine([$Date]);</div> | 
|  | 139 <p>Returns formatted lines representing empty CTAB block.</p> | 
|  | 140 </dd> | 
|  | 141 <dt><strong><a name="generatemisclinedatestamp" class="item"><strong>GenerateMiscLineDateStamp</strong></a></strong></dt> | 
|  | 142 <dd> | 
|  | 143 <div class="OptionsBox"> | 
|  | 144     $Line = GenerateMiscLineDateStamp();</div> | 
|  | 145 <p>Returns date stamp for misc line.</p> | 
|  | 146 </dd> | 
|  | 147 <dt><strong><a name="getallandcommoncmpddataheaderlabels" class="item"><strong>GetAllAndCommonCmpdDataHeaderLabels</strong></a></strong></dt> | 
|  | 148 <dd> | 
|  | 149 <div class="OptionsBox"> | 
|  | 150     ($CmpdCount, $DataFieldLabelsArrayRef, | 
|  | 151        $CommonDataFieldLabelsArrayRef) = | 
|  | 152           GetAllAndCommonCmpdDataHeaderLabels(\*SDFILE);</div> | 
|  | 153 <p>Returns number of comopunds, a reference to an array containing all unique data header | 
|  | 154 label and a reference to an array containing common data field labels for all compounds | 
|  | 155 in SD file.</p> | 
|  | 156 </dd> | 
|  | 157 <dt><strong><a name="getcmpddataheaderlabels" class="item"><strong>GetCmpdDataHeaderLabels</strong></a></strong></dt> | 
|  | 158 <dd> | 
|  | 159 <div class="OptionsBox"> | 
|  | 160     (@Labels) = GetCmpdDataHeaderLabels(\@CmpdLines);</div> | 
|  | 161 <p>Returns an array containg data header labels for a compound</p> | 
|  | 162 </dd> | 
|  | 163 <dt><strong><a name="getcmpddataheaderlabelsandvalues" class="item"><strong>GetCmpdDataHeaderLabelsAndValues</strong></a></strong></dt> | 
|  | 164 <dd> | 
|  | 165 <div class="OptionsBox"> | 
|  | 166     (%DataValues) = GetCmpdDataHeaderLabelsAndValues(\@CmpdLines);</div> | 
|  | 167 <p>Returns a hash conating data header labes and values for a compound.</p> | 
|  | 168 </dd> | 
|  | 169 <dt><strong><a name="getcmpdfragments" class="item"><strong>GetCmpdFragments</strong></a></strong></dt> | 
|  | 170 <dd> | 
|  | 171 <div class="OptionsBox"> | 
|  | 172     ($FragmentCount, $FragmentString) = GetCmpdFragments(\@CmpLines);</div> | 
|  | 173 <p>Figures out the number of disconnected fragments and return their values along | 
|  | 174 with the atom numbers in a string delimited by new line character. Fragment data | 
|  | 175 in <strong>FragmentString</strong> is sorted on based on its size.</p> | 
|  | 176 </dd> | 
|  | 177 <dt><strong><a name="getctablinescount" class="item"><strong>GetCtabLinesCount</strong></a></strong></dt> | 
|  | 178 <dd> | 
|  | 179 <div class="OptionsBox"> | 
|  | 180     $CtabLinesCount = GetCtabLinesCount(\@CmpdLines);</div> | 
|  | 181 <p>Returns number of lines present between the 4th line and the line containg "M END".</p> | 
|  | 182 </dd> | 
|  | 183 <dt><strong><a name="getinvalidatomnumbers" class="item"><strong>GetInvalidAtomNumbers</strong></a></strong></dt> | 
|  | 184 <dd> | 
|  | 185 <div class="OptionsBox"> | 
|  | 186     ($InvalidAtomNumbersCount, $InvalidAtomNumbers, $InvalidAtomNumberLines) = | 
|  | 187        GetInvalidAtomNumbers(\@CmpdLines);</div> | 
|  | 188 <p>Returns a list of values containing information about invalid atom numbers present | 
|  | 189 in block or atom property lines.</p> | 
|  | 190 </dd> | 
|  | 191 <dt><strong><a name="getunknownatoms" class="item"><strong>GetUnknownAtoms</strong></a></strong></dt> | 
|  | 192 <dd> | 
|  | 193 <div class="OptionsBox"> | 
|  | 194     ($UnknownAtomCount, $UnknownAtoms, $UnknownAtomLines) = | 
|  | 195        GetUnknownAtoms(\@CmpdLines);</div> | 
|  | 196 <p>Returns a list of values containing information about atoms which contain special element | 
|  | 197 symbols not present in the periodic table.</p> | 
|  | 198 </dd> | 
|  | 199 <dt><strong><a name="internalbondordertomdlbondtype" class="item"><strong>InternalBondOrderToMDLBondType</strong></a></strong></dt> | 
|  | 200 <dd> | 
|  | 201 <div class="OptionsBox"> | 
|  | 202     $MDLBondType = InternalBondOrderToMDLBondType($InternalBondOrder);</div> | 
|  | 203 <p>Returns value of <em>MDLBondType</em> corresponding to <em>InternalBondOrder</em>.</p> | 
|  | 204 <div class="OptionsBox"> | 
|  | 205     InternalBondOrder  MDLBondType</div> | 
|  | 206 <div class="OptionsBox"> | 
|  | 207       1                  1 | 
|  | 208      2                  2 | 
|  | 209      3                  3 | 
|  | 210      1.5                4</div> | 
|  | 211 </dd> | 
|  | 212 <dt><strong><a name="internalbondstereochemistrytomdlbondstereo" class="item"><strong>InternalBondStereochemistryToMDLBondStereo</strong></a></strong></dt> | 
|  | 213 <dd> | 
|  | 214 <div class="OptionsBox"> | 
|  | 215     $MDLBondStereo = InternalBondStereochemistryToMDLBondStereo( | 
|  | 216                      $InternalBondStereo);</div> | 
|  | 217 <p>Returns value of <em>MDLBondStereo</em> corresponding to <em>InternalBondStereo</em> using following | 
|  | 218 mapping:</p> | 
|  | 219 <div class="OptionsBox"> | 
|  | 220     InternalBondStereo  MDLBondStereo</div> | 
|  | 221 <div class="OptionsBox"> | 
|  | 222       Up          1 | 
|  | 223      UpOrDown    4 | 
|  | 224      Down        6 | 
|  | 225      CisOrTrans  3 | 
|  | 226      Other       0</div> | 
|  | 227 </dd> | 
|  | 228 <dt><strong><a name="internalchargetomdlcharge" class="item"><strong>InternalChargeToMDLCharge</strong></a></strong></dt> | 
|  | 229 <dd> | 
|  | 230 <div class="OptionsBox"> | 
|  | 231     $MDLCharge = InternalChargeToMDLCharge($InternalCharge);</div> | 
|  | 232 <p>Returns value of <em>MDLCharge</em> corresponding to <em>InternalCharge</em> using following | 
|  | 233 mapping:</p> | 
|  | 234 <div class="OptionsBox"> | 
|  | 235     InternalCharge  MDLCharge</div> | 
|  | 236 <div class="OptionsBox"> | 
|  | 237       3               1 | 
|  | 238      2               2 | 
|  | 239      1               3 | 
|  | 240 <br/>    -1              5 | 
|  | 241 <br/>    -2              6 | 
|  | 242 <br/>    -3              7</div> | 
|  | 243 </dd> | 
|  | 244 <dt><strong><a name="internalspinmultiplicitytomdlradical" class="item"><strong>InternalSpinMultiplicityToMDLRadical</strong></a></strong></dt> | 
|  | 245 <dd> | 
|  | 246 <div class="OptionsBox"> | 
|  | 247     $MDLRadical = InternalSpinMultiplicityToMDLRadical( | 
|  | 248                   $InternalSpinMultiplicity);</div> | 
|  | 249 <p>Returns value of <em>MDLRadical</em> corresponding to <em>InternalSpinMultiplicity</em>. These | 
|  | 250 value are equivalent.</p> | 
|  | 251 </dd> | 
|  | 252 <dt><strong><a name="mdlbondstereotointernalbondtype" class="item"><strong>MDLBondStereoToInternalBondType</strong></a></strong></dt> | 
|  | 253 <dd> | 
|  | 254 <div class="OptionsBox"> | 
|  | 255     $InternalBondType = MDLBondStereoToInternalBondType($MDLBondStereo);</div> | 
|  | 256 <p>Returns value of <em>InternalBondType</em> corresponding to <em>MDLBondStereo</em> using | 
|  | 257 mapping shown for <strong>InternalBondTypeToMDLBondStereo</strong> function.</p> | 
|  | 258 </dd> | 
|  | 259 <dt><strong><a name="iscmpd2d" class="item"><strong>IsCmpd2D</strong></a></strong></dt> | 
|  | 260 <dd> | 
|  | 261 <div class="OptionsBox"> | 
|  | 262     $Status = IsCmpd2D();</div> | 
|  | 263 <p>Returns 1 or 0 based on whether z-coordinate of any atom is non-zero.</p> | 
|  | 264 </dd> | 
|  | 265 <dt><strong><a name="iscmpd3d" class="item"><strong>IsCmpd3D</strong></a></strong></dt> | 
|  | 266 <dd> | 
|  | 267 <div class="OptionsBox"> | 
|  | 268     $Status = IsCmpd3D();</div> | 
|  | 269 <p>Returns 1 or 0 based on whether z-coordinate of any atom is non-zero.</p> | 
|  | 270 </dd> | 
|  | 271 <dt><strong><a name="mdlbondstereotointernalbondstereochemistry" class="item"><strong>MDLBondStereoToInternalBondStereochemistry</strong></a></strong></dt> | 
|  | 272 <dd> | 
|  | 273 <div class="OptionsBox"> | 
|  | 274     $InternalBondStereo = MDLBondStereoToInternalBondStereochemistry( | 
|  | 275                           $MDLBondStereo);</div> | 
|  | 276 <p>Returns value of <em>InternalBondStereo</em> corresponding to <em>MDLBondStereo</em> using | 
|  | 277 mapping shown for <strong>InternalBondStereochemistryToMDLBondStereo</strong> function.</p> | 
|  | 278 </dd> | 
|  | 279 <dt><strong><a name="mdlbondtypetointernalbondorder" class="item"><strong>MDLBondTypeToInternalBondOrder</strong></a></strong></dt> | 
|  | 280 <dd> | 
|  | 281 <div class="OptionsBox"> | 
|  | 282     $InternalBondOrder = MDLBondTypeToInternalBondOrder($MDLBondType);</div> | 
|  | 283 <p>Returns value of <em>InternalBondOrder</em> corresponding to <em>MDLBondType</em> using | 
|  | 284 mapping shown for <strong>InternalBondOrderToMDLBondType</strong> function.</p> | 
|  | 285 </dd> | 
|  | 286 <dt><strong><a name="mdlchargetointernalcharge" class="item"><strong>MDLChargeToInternalCharge</strong></a></strong></dt> | 
|  | 287 <dd> | 
|  | 288 <div class="OptionsBox"> | 
|  | 289     $InternalCharge = MDLChargeToInternalCharge($MDLCharge);</div> | 
|  | 290 <p>Returns value of <em>$InternalCharge</em> corresponding to <em>MDLCharge</em> using | 
|  | 291 mapping shown for <strong>InternalChargeToMDLCharge</strong> function.</p> | 
|  | 292 </dd> | 
|  | 293 <dt><strong><a name="mdlradicaltointernalspinmultiplicity" class="item"><strong>MDLRadicalToInternalSpinMultiplicity</strong></a></strong></dt> | 
|  | 294 <dd> | 
|  | 295 <div class="OptionsBox"> | 
|  | 296     $InternalSpinMultiplicity = MDLRadicalToInternalSpinMultiplicity( | 
|  | 297                                 $MDLRadical);</div> | 
|  | 298 <p>Returns value of <em>InternalSpinMultiplicity</em> corresponding to <em>MDLRadical</em>. These | 
|  | 299 value are equivalent.</p> | 
|  | 300 </dd> | 
|  | 301 <dt><strong><a name="parsecmpdatomaliaspropertyline" class="item"><strong>ParseCmpdAtomAliasPropertyLine</strong></a></strong></dt> | 
|  | 302 <dd> | 
|  | 303 <div class="OptionsBox"> | 
|  | 304     @AtomNumAndValuePairs = ParseCmpdAtomAliasPropertyLine( | 
|  | 305                             $CurrentLine, $NexLine);</div> | 
|  | 306 <p>Parses atom alias propery lines in CTAB generic properties block and returns an array | 
|  | 307 with successive pairs of values corresponding to atom number and its alias.</p> | 
|  | 308 </dd> | 
|  | 309 <dt><strong><a name="parsecmpdatomline" class="item"><strong>ParseCmpdAtomLine</strong></a></strong></dt> | 
|  | 310 <dd> | 
|  | 311 <div class="OptionsBox"> | 
|  | 312     ($AtomSymbol, $AtomX, $AtomY, $AtomZ, $MassDifference, $Charge, | 
|  | 313        $StereoParity) = ParseCmpdAtomLine($AtomDataLine);</div> | 
|  | 314 <p>Parses compound data line containing atom information and returns a list | 
|  | 315 of values.</p> | 
|  | 316 </dd> | 
|  | 317 <dt><strong><a name="parsecmpdbondline" class="item"><strong>ParseCmpdBondLine</strong></a></strong></dt> | 
|  | 318 <dd> | 
|  | 319 <div class="OptionsBox"> | 
|  | 320     ($FirstAtomNum, $SecondAtomNum, $BondType) = | 
|  | 321        ParseCmpdBondLine($BondDataLine);</div> | 
|  | 322 <p>Parses compound data line containing bond information and returns a list of | 
|  | 323 values.</p> | 
|  | 324 </dd> | 
|  | 325 <dt><strong><a name="parsecmpdcommentsline" class="item"><strong>ParseCmpdCommentsLine</strong></a></strong></dt> | 
|  | 326 <dd> | 
|  | 327 <div class="OptionsBox"> | 
|  | 328     $Comments = ParseCmpdCommentsLine($CommentsDataLine);</div> | 
|  | 329 <p>Returns the comment string.</p> | 
|  | 330 </dd> | 
|  | 331 <dt><strong><a name="parsecmpdchargepropertyline" class="item"><strong>ParseCmpdChargePropertyLine</strong></a></strong></dt> | 
|  | 332 <dd> | 
|  | 333 <div class="OptionsBox"> | 
|  | 334     @AtomNumAndValuePairs = ParseCmpdChargePropertyLine( | 
|  | 335                             $ChargeDataLine);</div> | 
|  | 336 <p>Parses charge propery line in CTAB generic properties block and returns an array | 
|  | 337 with successive pairs of values corresponding to atom number and its charge.</p> | 
|  | 338 </dd> | 
|  | 339 <dt><strong><a name="parsecmpdcountsline" class="item"><strong>ParseCmpdCountsLine</strong></a></strong></dt> | 
|  | 340 <dd> | 
|  | 341 <div class="OptionsBox"> | 
|  | 342     ($AtomCount, $BondCount, $ChiralFlag, $PropertyCount, $Version) = | 
|  | 343        ParseCmpdCountsLine(\@CountDataLines);</div> | 
|  | 344 <p>Returns a list of values containing count information.</p> | 
|  | 345 </dd> | 
|  | 346 <dt><strong><a name="parsecmpdmiscinfoline" class="item"><strong>ParseCmpdMiscInfoLine</strong></a></strong></dt> | 
|  | 347 <dd> | 
|  | 348 <div class="OptionsBox"> | 
|  | 349     ($UserInitial, $ProgramName, $Date, $Code, $ScalingFactor1, $ScalingFactor2, | 
|  | 350        $Energy, $RegistryNum) =  ParseCmpdMiscInfoLine($Line);</div> | 
|  | 351 <p>Returns a list of values containing miscellaneous information.</p> | 
|  | 352 </dd> | 
|  | 353 <dt><strong><a name="parsecmpdisotopepropertyline" class="item"><strong>ParseCmpdIsotopePropertyLine</strong></a></strong></dt> | 
|  | 354 <dd> | 
|  | 355 <div class="OptionsBox"> | 
|  | 356     @AtomNumAndValuePairs = ParseCmpdIsotopePropertyLine( | 
|  | 357                             $IsotopeDataLine);</div> | 
|  | 358 <p>Parses isotopic propery line in CTAB generic properties block and returns an array | 
|  | 359 with successive pairs of values corresponding to atom number and absolute mass of | 
|  | 360 atom isotope.</p> | 
|  | 361 </dd> | 
|  | 362 <dt><strong><a name="parsecmpdmolnameline" class="item"><strong>ParseCmpdMolNameLine</strong></a></strong></dt> | 
|  | 363 <dd> | 
|  | 364 <div class="OptionsBox"> | 
|  | 365     $MolName = ParseCmpdMolNameLine($Line);</div> | 
|  | 366 <p>Returns a string containing molecule name.</p> | 
|  | 367 </dd> | 
|  | 368 <dt><strong><a name="parsecmpdradicalpropertyline" class="item"><strong>ParseCmpdRadicalPropertyLine</strong></a></strong></dt> | 
|  | 369 <dd> | 
|  | 370 <div class="OptionsBox"> | 
|  | 371     @AtomNumAndValuePairs = ParseCmpdRadicalPropertyLine( | 
|  | 372                             $RadicalDataLine);</div> | 
|  | 373 <p>Parses radical propery line in CTAB generic properties block and returns an array | 
|  | 374 with successive pairs of values corresponding to atom number and radical number | 
|  | 375 value.</p> | 
|  | 376 </dd> | 
|  | 377 <dt><strong><a name="removecmpddataheaderlabelandvalue" class="item"><strong>RemoveCmpdDataHeaderLabelAndValue</strong></a></strong></dt> | 
|  | 378 <dd> | 
|  | 379 <div class="OptionsBox"> | 
|  | 380     $NewCmpdString = RemoveCmpdDataHeaderLabelAndValue($CmpdString, | 
|  | 381                                                        $DataHeaderLabel);</div> | 
|  | 382 <p>Returns a <strong>NewCmpdString</strong> after removing  <em>DataHeaderLabel</em> along with its | 
|  | 383 value from <em>CmpdString</em>.</p> | 
|  | 384 </dd> | 
|  | 385 <dt><strong><a name="readcmpdstring" class="item"><strong>ReadCmpdString</strong></a></strong></dt> | 
|  | 386 <dd> | 
|  | 387 <div class="OptionsBox"> | 
|  | 388     $CmpdString = ReadCmpdString(\*SDFILEHANDLE);</div> | 
|  | 389 <p>Returns a string containing all the data lines for the next available compound | 
|  | 390 in an already open file indicated by SDFILEHANDLE. A NULL string is returned | 
|  | 391 on EOF.</p> | 
|  | 392 </dd> | 
|  | 393 <dt><strong><a name="washcmpd" class="item"><strong>WashCmpd</strong></a></strong></dt> | 
|  | 394 <dd> | 
|  | 395 <div class="OptionsBox"> | 
|  | 396     ($FragmentCount, $Fragments, $WashedCmpdString) = | 
|  | 397        WashCmpd(\@CmpdLines);</div> | 
|  | 398 <p>Figures out the number of disconnected fragments and return their values along | 
|  | 399 with the atom numbers in a string delimited by new line character. Fragment data | 
|  | 400 in <strong>FragmentString</strong> is sorted on based on its size.</p> | 
|  | 401 </dd> | 
|  | 402 </dl> | 
|  | 403 <p> | 
|  | 404 </p> | 
|  | 405 <h2>AUTHOR</h2> | 
|  | 406 <p><a href="mailto:msud@san.rr.com">Manish Sud</a></p> | 
|  | 407 <p> | 
|  | 408 </p> | 
|  | 409 <h2>SEE ALSO</h2> | 
|  | 410 <p><a href="./TextUtil.html">TextUtil.pm</a> | 
|  | 411 </p> | 
|  | 412 <p> | 
|  | 413 </p> | 
|  | 414 <h2>COPYRIGHT</h2> | 
|  | 415 <p>Copyright (C) 2015 Manish Sud. All rights reserved.</p> | 
|  | 416 <p>This file is part of MayaChemTools.</p> | 
|  | 417 <p>MayaChemTools is free software; you can redistribute it and/or modify it under | 
|  | 418 the terms of the GNU Lesser General Public License as published by the Free | 
|  | 419 Software Foundation; either version 3 of the License, or (at your option) | 
|  | 420 any later version.</p> | 
|  | 421 <p> </p><p> </p><div class="DocNav"> | 
|  | 422 <table width="100%" border=0 cellpadding=0 cellspacing=2> | 
|  | 423 <tr align="left" valign="top"><td width="33%" align="left"><a href="./PseudoHeap.html" title="PseudoHeap.html">Previous</a>  <a href="./index.html" title="Table of Contents">TOC</a>  <a href="./SequenceFileUtil.html" title="SequenceFileUtil.html">Next</a></td><td width="34%" align="middle"><strong>March 29, 2015</strong></td><td width="33%" align="right"><strong>SDFileUtil.pm</strong></td></tr> | 
|  | 424 </table> | 
|  | 425 </div> | 
|  | 426 <br /> | 
|  | 427 <center> | 
|  | 428 <img src="../../images/h2o2.png"> | 
|  | 429 </center> | 
|  | 430 </body> | 
|  | 431 </html> |