Power BI Custom Visual Part 5 – Formatting

Setting up the formatting options turns out to be the most fiddly bit of developing a custom visual. There are a few “special” property names that are required to trigger some behaviours, undocumented features and at least one bug that I’ve come across. In this section I’ll explain how the options are set up for the Tree Funnel visual and in an extra post I’ll talk about some of the other issues and features. Continue reading “Power BI Custom Visual Part 5 – Formatting”

Power BI Custom Visual Part 4 – Accessing the DataView

In understanding how to access the data in a custom visual I found AB Kimmel’s tutorial incredibly helpful. Here I’m just going to go through the options I need, for a broader explanation I’d recommend reading his sections on data views. There are four steps to go through. First specify what data can be added to the visual via the Fields pane – this data will then be accessible via the dataview. Then create a data model to hold this data and a function to populate it from the dataview. And finally use the data model data to draw the visual. Continue reading “Power BI Custom Visual Part 4 – Accessing the DataView”

Power BI Custom Visual Part 2A – SVG blend lines between elements

When drawing the paths for the Tree Funnel visual I noticed an unsightly line between each horizontal. Initially I thought this would be due to a small error in the stroke width introducing a gap but actually the calculation is perfect and each path is exactly adjacent. The lines are actually due to the anti-aliasing of each path. Continue reading “Power BI Custom Visual Part 2A – SVG blend lines between elements”

Power BI Custom Visual Part 2 – Creating a Tree Funnel Chart

Power BI Visuals basically render a bunch of HTML to display a chart. Typically these will be SVG elements and most likely use the D3 library to help draw them. So when I started on developing a Power BI Custom Visual it made sense to develop the chart rendering separately and worry about how to hook it into the Power BI Visual after I was happy with the basic chart logic. This section then is purely D3. Continue reading “Power BI Custom Visual Part 2 – Creating a Tree Funnel Chart”

Power BI Custom Visuals Part 1 – Introduction

I’d been interested in developing a Power BI custom visual for a while before actually getting round to producing something. The usual constraints on time were one reason but also the rather limited documentation and the number of components required which I have at best a surface knowledge of: Typescript and D3 in particular. Having finally found the time I found that the process was not too painful even starting from a pretty low base. The documentation however was sparse and so before detailing how I got on I thought I’d outline the resources I found useful. Continue reading “Power BI Custom Visuals Part 1 – Introduction”

Handling Overlapping Academic Years

Comparing measures year on year is normally a trivial task. Drop your years into the columns of a matrix and months into the rows and there you go. This all works so long as the dates in the years you’re comparing don’t “overlap”. How can they overlap? An example is the best way to illustrate this issue. Say we’re comparing student withdrawals between academic years which run SEP to AUG. But withdrawals from an academic year may be recorded with a date after the end the actual end of the academic year. Continue reading “Handling Overlapping Academic Years”

Aggregate Traffic Light KPI with Variable Targets in Power BI and Analysis Services Tabular

Setting up a KPI to monitor performance against a single target is simple enough in SSAS (it’s also possible directly in Power BI but I’ll only deal with the SSAS approach here). However if you have different targets for different dimension values then a bit more thought is required. As an example imagine different courses are set different targets for student withdrawals in an academic year. Continue reading “Aggregate Traffic Light KPI with Variable Targets in Power BI and Analysis Services Tabular”

Downloading Blackboard Data from Snowflake DB in .NET

Blackboard Data provides access to data about activity on your Blackboard LMS via the Blackboard reporting stack. The data is stored in a Snowflake data warehouse instance. Here you can query the data directly via the Snowflake console or connect a reporting tool such as tableau or Power BI. But what if you want to export the data out of snowflake, for example to an institutional data warehouse. There are number of ways to do this but .NET is my preferred platform so that is what I’ll be using. The Snowflake documentation on this makes the task look quite confusing- but actually it’s very straightforward. Here’s how to connect to and download from Snowflake to an on premise SQL Server instance. Continue reading “Downloading Blackboard Data from Snowflake DB in .NET”

Applications by UK Region: A Choropleth Map in Power BI

The Power BI shape map allows you to create simple choropleths (a map where the shading of a map region indicates some value) but comes with a very limited set of map regions. For the UK you only get UK countries so if you want to show other UK regions, you’ll have to source additional maps. Here I’ll show how you can map student applications by UK NUTS regions (Nomenclature of Territorial Units for Statistics). Continue reading “Applications by UK Region: A Choropleth Map in Power BI”