Let’s now have a look into a cloud-based BI tool, Amazon Quicksight.
Amazon QuickSight is a fast, cloud-powered business intelligence (BI) service that makes it easy for you to deliver insights to everyone in your organization.
QuickSight lets you create and publish interactive dashboards that can be accessed from browsers or mobile devices. You can embed dashboards into your applications, providing your customers with powerful self-service analytics. QuickSight easily scales to tens of thousands of users without any software to install, servers to deploy, or infrastructure to manage.
With the industry’s first pay-per-session billing model, you only pay for what you use. This allows you to give all of your users access to the data they need without expensive per-seat licenses.
In this section we prepare your AWS account for using Amazon Quicksight.
When you go to the Amazon Quicksight console, it tells you that your AWS account is not signed up to Amazon Quicksight. Click the Sign up for Quicksight
button.
On the next screen, select Standard
configuration. Scroll down to the bottom of the page and click the Continue
button.
On the next screen, ignore the warning This IAM user or role may not have all the correct permissions to subscribe to QuickSight...
if you see it in a red box at the top of the screen. Scroll down and make sure that there is a tick in the check box next to Amazon Athena
. Then click directly below on Amazon S3
or Choose S3 buckets
and select the name of your processing bucket that holds all data about your call recordings.
Also enter a unique value in QuickSight account name
and a valid email address in Notification email address
and click on the Finish
button. Your Amazon Quicksight account is being created.
After a few moments, you’re all set to use Amazon Quicksight. You should see a message similar to Congratulations! You are signed up for Amazon QuickSight!
and a button Go to Amazon Quicksight
. Click on that button to continue.
Now you’re back to the Amazon Quicksight console. In case you see a What's New in Amazon Quicksight
pop-up, click on the Close
button to continue. Make sure the right region (Northern Virginia) is still selected in the upper right corner. Click the New analysis
button in the top left corner.
On the next screen, click the New data set
button.
On the next screen you select your data source. In our case, we want to visualize data from an Amazon Athena table. Hence we click the Athena
tile.
We’are asked to provide a name to our data source. Please use connect-comprehend
.
Then click the Validate connection
button to double check that Amazon Quicksight is entitled to interact with Amazon Athena on your behalf. Click the Create data source
button to continue.
We need to select the database from Amazon Athena (effectively, it’s provided by AWS Glue) that contains our sentiment analysis table. You can open the Amazon Athena console (or the AWS Glue console) in another tab to have the names at hand. Once you have selected the right database (starting with comprehendgluedatabase
), you will see the table named sentiment_analysis
that you know already from your previous experiments with Amazon Athena.
Click the Use custom SQL
button to continue, not the Select
button.
Now you can enter your custom SQL query. This is required because, as you have seen before when you ran the queries in Amazon Athena, some values in the virtual table contain nested arrays. The custom SQL query we’re going to use now will unnest these values.
Use an arbitrary name for your query, e.g. sentiment-query
, in the text field pre-filled with New custom SQL
. Then use the following query for the Enter SQL here...
text area and replace <YOUR DATABASE NAME>
with your virtual database that contains your sentiment_analysis
table.
WITH sentiment AS (
SELECT
contactid,
talker,
text,
sentiment
FROM
"<YOUR DATABASE NAME>"."sentiment_analysis"
)
SELECT
contactid,
talker,
transcript,
sentimentresult.sentiment,
sentimentresult.sentimentscore.positive,
sentimentresult.sentimentscore.negative,
sentimentresult.sentimentscore.mixed
FROM
sentiment CROSS
JOIN
UNNEST(text) as t(transcript) CROSS
JOIN
UNNEST(sentiment) as t(sentimentresult)
Click the Confirm query
button to continue.
In the Finish data set creation
dialog, leave everything untouched and click the Visualize
button.
On the screen you land now, please observe the box in the top right corner. When it says Import complete
you can start constructing your visualizations. Let’s make use of the AutoGraph
tile first, before you can later explore the other options.
Select the sentiment
and the talker
fields and see how they are visualized in the AutoGraph
tile.
Open the drop down list in the upper right corner of the AutoGraph
tile and click the Maximize
option. If you couldn’t see the color codes for the diagram before, you can now. How does your visualization look like?
You can now play with the various diagram types and explore Amazon Quicksight as you like. Discuss within your team what makes sense to your business.
Congratulations!
You have successfully used Amazon Quicksight to visualize your processing data.