Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
The purpose of this tutorial is to analyze and compare the market value of companies over time. To do this, we will see step by step how to download data from the Yahoo Finance site and then how to import this data into Power BI and process it in order to create a report.
Step I: Downloading data from the Yahoo Finance website
In this step you should:
4. Indicate the maximum duration (you should select "Max" in order to have all historical data)
5. Select "Daily" for frequency
6. Click on “Apply”
7. Finally, click on “download“.
NB: Repeat the same steps for all the desired companies.
In this tutorial we will take a second company, Google (GOOG symbol).
Step II: Data processing on Power BI Desktop
In the previous step we downloaded the Facebook and Google data from the Yahoo Finance site. Now we will import and process this data. It should be noted that for this tutorial, we used the version: 2.75.5649.961 64-bit (November 2019) of Microsoft Power BI Desktop.
Editing Queries
On the Home tab, in the External data group, click on "Edit queries".
Taking into account the number of shares.
Here, we have to go to the Yahoo Finance site to get a hold of a statistical value called "Shares Outstanding". To do this, we must:
NB: Do the same for Google.
This value will be used in the Stat table which we will create later.
Creating the Stat table
Conversion of Columns (Low, high) to decimal
NB: Do the same for The High column and Adj Close.
Merging the table (Facts and Stat)
It is time to merge our two tables. As a prerequisite, we must make sure that the Company columns have the same content:
1. Right click on the “Company” column, click on “Replace values”.
we will replace “. Csv” by a vacuum.
We can do the merger
2. In Home, click "Merge Queries" in the Combine group.
3. Click on the rectangle to add the Stat table
4. Click on the common columns (in this case Company), from which the merger will take place
5. Click ok.
Expand the Stat column
1. Right click on the symbol to the right of the Stat column
Select the field “shares Outstanding”
Addition of columns (Events and Market Cap)
* Events
In this pane we will add the column “Events”:
* Market Cap
The approach is the same as in “Events”, with the creation of a Custom Column.
The difference is at the level of the formula and the name of the column.
Apply changes
1. To complete part 2, right click on the file and click on Apply
Step III: Visualization
At the end of step 2, we clicked on apply so that the modifications made in
the Query Editor are taken into account. In this last step, we should come back
to the first window to display visual elements.
To do this you must:
Tutorial by Roméo Brunège Kouata, MYPE.
Original idea by Augustin de la Fouchardiere, MYPE
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.