Generate Business Intelligence Reports From Wikipedia Using Power BI

Power BI is a Cloud based Service which provides data visualization options based on the source data. Using Power BI, we can create dashboards, which are based on the data. While using Power BI, make sure that you have a Power BI account. If you don’t have an account, you can sign up for it here .You can either work with Power BI online or download Power BI desktop version here.

Power BI

Power BI has the flexibility to consume numerous data sources and generate business intelligence reports from the source data. In this article, we will see how to consume JSON data from a Wikipedia page within Power BI and create the reports using Wiki Table data. We will be connecting to the "Highest Mountain on Earth" Wiki page and we will create bar chart reports based on the height of the mountains.

Power BI

Connect to Wikipedia

Before getting started with report generation, we have to connect to the Wikipedia data source. In order to do that, spin up Power BI Desktop and select ‘Get data’ option.

Power BI

Select Web option and click on Connect.

Power BI

This will open up a pop up where we can specify the Wikipedia page URL. Click on OK.

Power BI

Specify the connection type as Anonymous and select the Page URL from the drop down. Finally, click on Connect to get connected with Wikipedia page.

Power BI

It will list the type of data that is available from the page URL that we had specified. Select the checkbox against ‘List’ so as to connect to the table within the Wikipedia page.

Power BI

Upon selecting the checkbox, the table in the page has been populated adjacent to it.

Power BI

Click on "Load" to populate a copy of the table within PowerBI.

Power BI

Create BI Reports

Go to the table page as shown below. We can see the loaded data within PowerBI.

Power BI

Go back to the visualization page so as to create reports based on the loaded data.

Power BI

From the visualization section, we will select bar chart as the choice of report generation option for the time being. To the right of the page, we can see the entire table columns that we can use for creating bar charts.

Power BI

We will use only the required columns. As we are plotting Mountain versus Mountain height, let's drag Moutain Cloum to the X Axis and the Height Column to the Y axis (Values) section.

Power BI

This will generate the bar chart report. Since we have not restricted the data, the entire mountain range within the table will be plotted in the bar chart making it congested.

Power BI

To get meaningful data, we can apply filter so that only the required data will be plotted in the bar chart. Now, we have applied the filter such that only mountain with a height above 8400 metres are taken up for plotting in the bar chart.

Power BI

We can customize the already created bar chart by adding colors, changing the font size, and so on from the customization section as shown below.

Power BI

Publish to Power BI Online

Finally, we can publish the report to Power BI online.

Power BI

Specify the credentials and click on Sign in.

Power BI

Select "My workspac"e as the destination to publish the report.

Power BI

Clicking on select will start the publishing of the report to Power BI online.

Power BI

Finally, we have received the success message as shown below.

Power BI

Heading over to Power BI Online, we can view the recently created report.

Power BI

We can also change the filters directly from the online report.

Power BI

Summary

Thus, we saw how we can make use of Wikipedia data and generate business intelligence reports using Power BI.