title: Using d3 to import .csv data error: 404: Not Found error
body: <p>EDIT: I've read more about using Rails &amp; D3 and the advice I've heard is use JSON for incoming data and make your life easier. Lesson learned.</p>
  
  <p>Basic Ruby/Rails app, creating a stock chart with d3.  However, I cannot seem to load my dataset (in this case .csv file saved inside the rails app. Console shows this error:</p>
  
  <p>"GET http:// localhost:3000/pages/sp500.csv 404 (Not Found)" (space added)</p>
  
  <p>My code: </p>
  
  <pre><code>    d3.csv("sp500.csv", function (data) {
  
        data.forEach(function(d) {
        d.date = parseDate(d.date);
        d.price = +d.price;
      });
  </code></pre>
  
  <p>Tried saving the sp500.csv in various directories and calling it in variety of ways, but still stuck.  Thanks for help. </p>