title: JS Extract numbers in parentheses from text file and filter out to be used in calculation
body: <p>My text file has some numbers in parentheses that I would like to extract and use them in a function for some calculation. I have the code below to filter out the strings from the text file and output them... but I'd also like to use the numbers for calculations. like below is an example of I'd like to extract from text file.</p>
  
  <p>passage (16333.614,-8500.850),(13000.638,-10465.827),(7775.276,-15735.827)</p>
  
  <pre><code>function readText(that){
  
          if(that.files &amp;&amp; that.files[0]){
              var reader = new FileReader();
              reader.onload = function (e) {  
                  var output=e.target.result;
                  var output2=e.target.result;
                  var output3=e.target.result;
                  var output4=e.target.result;        
  
                  output=output.split("\n").filter(/./.test, /country/);
                  output2=output2.split("\n").filter(/./.test, /\passage/).join("\n");
                  output3=output3.split("\n").filter(/./.test, /\country side/).join("\n");   
                  output4=output4.split("\n").filter(/./.test, /test/).join("\n");
                  document.getElementById('inputTextToSave').innerHTML= output + output2 + output3 + output4;
  </code></pre>