Homework H19
Fincharts!
Learning Goals
Creating financial charts from data retrieved from a remote database.
Context
“VISUALIZATION is the mother of the most EXQUISITE data analysis. The best traders at LongShort - like Maya” Mr. Stockton continues, “not
only understand financial models and the underlying economics — they are also well versed at reading charts.”
Maya beams a huge smile. She heard the praise.
“That makes sense,” you reply, “charts are a great way to spot trends and patterns.”
“Your reasoning is UNIMPEACHABLE!” he declares.
A couple of traders glance up from their screens. 'Unimpeachable'?
“We must therefore add to the Spartan Trader the ability to produce real-time charts of the securities in our universe.”
You nod. "We" meant "you", but compared with portfolio metrics and execution engines, this one feels like a walk in Central Park.
“Of course,” you say, “I am on it, Boss.”
Task
Build a system that satisfies the requirements.
Want to submit as a team? These are are instructions.
Criteria/Requirements
Your work must satisfy the following requirements
Hints and Tips
Patches
The video misses a couple of functions, that you can copy and paste below
Public Function DownloadDataForStockChart(ticker As String) As DataTable
Dim mySQL As String
ticker = ticker.Trim()
If ticker = "SP500" Then
mySQL = "Select date, value as 'ask', value as 'bid' from stockindex
where Symbol = 'SNP'"
Else
mySQL = "Select date, bid, ask from stockmarket where ticker = '" &
ticker & "'"
End If
Return RunQuery(mySQL)
End Function
Public Function DownloadDataForOptionChart(symbol As String) As DataTable is left for you to complete as part of
the assignment.