Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

Extracting Angle Data


  • Please log in to reply
2 replies to this topic
tmcando
  • Members
  • 2 posts
  • Last active: Apr 05 2017 06:45 AM
  • Joined: 15 Sep 2013

My objective is to extract the angle of direction (in degrees) of a pictorial arrow shown on a website. The context to this issue is that the web page is a weather forecast that includes hourly predictions of the wind speed and direction. The wind direction is shown only as a pictorial arrow, however I need that info as numerical data (in degrees) for use in another program that compares the forecast with actual data.

 

My proposed approach is to:-

1.       Use AHK to open the weather forecast webpage; and then

2.       Use AHK to manipulate the “Meazure software” (an on screen measuring tool) to measure the arrow direction (for each hour); and then

3.       Use AHK to write that data to an excel file; and then

4.       Use AHK to copy the wind speed data from the web page to the excel file.

 

Writing such a script is too challenging for my basic skills. I appreciate any kind assistance in helping me achieve this task. Thanks.



smorgasboard
  • Members
  • 660 posts
  • Last active: Jan 14 2016 08:53 AM
  • Joined: 18 Jul 2012

Post more details.



kon
  • Members
  • 1652 posts
  • Last active:
  • Joined: 04 Mar 2013

1.       Use AHK to open the weather forecast webpage; and then
2.       Use AHK to manipulate the “Meazure software” (an on screen measuring tool) to measure the arrow direction (for each hour); and then
3.       Use AHK to write that data to an excel file; and then
4.       Use AHK to copy the wind speed data from the web page to the excel file.


1. We will need to know the webpage, or at least we will need to look at the html. Some weather sites have rss feeds that may be a better source of data than an image.
2. There is almost certainly a better way to do this natively in AHK. For example: Compass - Measure angles and scale distances with your mouse. But a better solution could be to extract it from the html. We need to see the page to know what we are dealing with though.
3/4. See Basic Ahk_L COM Tutorial for Excel and then MS Office COM Basics.