0

I want to use importrange to pull in just the high/low data during a specific time of the day, ignoring the rest of the days update. Specifically from 8:30am to 2:50pm weekdays only.

=importhtml("http://www.marketwatch.com/investing/stock/aapl"&"?"&"workaround="&INT(NOW()),"table")

So for example, I only want to pull in the specific data starting at 8:30am and ending at 2:50pm

Rubén
  • 34,714
  • 9
  • 70
  • 166
Josh W
  • 11
  • 1

1 Answers1

0

The =importhtml() function doesn't have the have the ability to filter data. The query parameter is for:

query - Either "list" or "table" depending on what type of structure contains the desired data.

You can import the data, then run a =query() on the imported data, using the range that the imported data is displayed in.

That URL only has one table in it, and it's not the data for the aapl stock chart. There are 8 lists in that web page, but none of them are for the data in the aapl stock. You aren't going to be able to scrape that chart with =importurl()

The chart is in a <canvas> tag.

Alan Wells
  • 30,746
  • 15
  • 104
  • 152
  • so how would the formula look with the time constraint of 8:30 to 2:50? Thanks – Josh W Mar 16 '15 at 03:47
  • Here is a better example of a link that Im import data from https://docs.google.com/spreadsheets/d/1ueEoUot0rrAyD9m0JMkXsjmNIQ2I5imWmfF2DGMrsRQ/edit?usp=sharing – Josh W Mar 16 '15 at 06:06
  • It looks like the website you are getting the data from has "deep linking", and the website *itself* filters data from a search string at the end of the URL? The website itself needs to be filtering the data. If that's not happening, then the `=importhtml` function can't do anything. Does the website correctly filter the data with the right search string on the end? – Alan Wells Mar 16 '15 at 14:20