Business Intelligence Stefano Grazioli
Critical Thinking Bug bounty Easy Meter
You do the talking Name, major Learning objectives Things you like about the class Things that can be improved Strengths / Attitude towards the Tournament
Homework Google’s Daily Cagr
Daily Cagr for Google You are an analyst at a broker firm. Many of our customers invest for short amounts of time on Google. They sell their shares within a few weeks…. I wonder: do they make any money out of it?
UML Activity Diagram - Daily Compound Average Growth of a Security (part II) The user press the Compute Cagr button Compute the Cagr for the next customer [(final price/initial price)^1/days ]-1 Print the result for that customer. In red if it is negative. Print the Average of all Cagrs at the bottom of the Cagr column, with a descriptive label. [No More Customers]
Suggestions Video available Give yourself plenty of time
What Is New In Technology? WINIT What Is New In Technology?
Dates
Dates Dim myDate As Date = "11/14/2002“ Year = myDate.Year MyDate Month = myDate.Month Day = myDate.Day DOW = myDate.DayOfWeek DOY = myDate.DayOfYear ... MyDate Year 2002 Month 11 Day 14 Week 45 .... ...
A TimeSpan represents the elapsed time between two dates. Dim myDate1 As Date Dim myDate2 As Date Dim myTS As TimeSpan myDate1 = Range("A1").Value myDate2 = Range("A2").Value myTS = myDate2 - myDate1 Range("A3").Value = myTS.Days Date1 Date2 TIMESPAN
TimeSpan mySpan.Days gives you the total number of days mySpan.TotalDays gives you the total number of days, plus a fraction of day based on the hours
Cagr [(final price/initial price)^(1/days)]-1 See the timespan slide example. You will need to use the .Days value rather than printing it out.
Manipulations used in data quality and beyond Strings Manipulations used in data quality and beyond
Strings and Characters Dim myString As String = “This is a sample string" Dim myString2 As String = "s" Dim myChar As Char = "s"c
Testing Numbers Dim myString As String = "#2344-234-33-3" Dim temp As String = "" For Each x As Char In myString If IsNumeric(x) Then temp = temp + x End If Next
Inserting and Removing Dim myStr As String = "This is a sample string" myStr = myStr.Insert(4, "xyz") myStr = myStr.Remove(4, 3) 'starting where,how many myStr = myStr.Replace(" is", " was") myStr = myStr.Substring(0, 9) + “ another " + myStr.Substring(10, 13) + "."
Finding Dim myStr As String = "This is a sample string" Dim myPosition As Integer = 0 myPosition = myStr.IndexOf("s")
Total length of the result Trimming and Padding myLenght = myString.Length myNewString = myString.Trim() myNewString = myString.TrimEnd() myNewString = myString.TrimStart() myNewString = myString.PadLeft(50) myNewString = myString.PadRight(20) Total length of the result