How to scrape a public tableau dashboard

0 votes
This is a question that has to be narrowed down. It is currently not accepting responses.

Do you have any suggestions for how to improve this question? By changing this post, you may change the question to focus on a single issue.

1 year ago, this business was closed.

Every day, I have to download data from a publicly accessible Tableau dashboard. The dashboard allows you to download the series when you've defined the parameters of interest (time series frequency, time series interval, and so on).

My life would be a lot simpler if I could use Python or R to automate the download of these series to a database. I tried to evaluate the requests made on the website before, but I couldn't go very far. Is it possible to automate this process?

https://tableau.ons.org.br/t/ONS Publico/views/DemandaMxima/Histrico

DemandaMxima?:embed=y&:showAppBanner=false&:showShareOptions=true&:display count=no&:showVizHome=no
Mar 4, 2022 in Tableau by Vaani
• 7,070 points
1,665 views

1 answer to this question.

0 votes

To extract data from Tableau workbooks, I created a tableau scraper library.

You may easily import data from workbooks into a pandas dataframe. Also supported are the parametered values.

The following example obtains data from the worksheet Simples Demanda Máxima Ano, switches to daily mode, displays the data from the worksheet Simples Demanda Máxima Semana Dia, and then sets the start date to January 1, 2021:

FROM tableauscraper IMPORT TableauScraper AS TS

url = "https://tableau.ons.org.br/t/ONS_Publico/views/DemandMaxima/HistricoDemandMaxima"

ts = TS()
ts.loads(url)
wb = ts.getWorkbook()

# dataframe with yearly data
ws = wb.getWorksheet("Simples Demanda Máxima Ano")
print(ws.data)

# switch to daily
wb = wb.setParameter("Escala de Tempo DM Simp 4", "Dia")

# dataframe with daily data
ws = wb.getWorksheet("Simples Demanda Máxima Semana Dia")
print(ws.data)

# switch to daily
wb = wb.setParameter(
    "Início Primeiro Período DM Simp 4", "01/01/2021")

# show dataframe with daily data from 01/01/2021
ws = wb.getWorksheet("Simples Demanda Máxima Semana Dia")
print(ws.data)
answered Mar 4, 2022 by Neha
• 9,020 points

Related Questions In Tableau

0 votes
1 answer

How to count occurrence of value and percentage of a subset in tableau public?

Although it sounds like a fairly easy ...READ MORE

answered Jun 5, 2018 in Tableau by Atul
• 10,240 points
11,773 views
0 votes
1 answer

How to color code cells of a column based on the text value in Tableau

You can use the following steps to ...READ MORE

answered Mar 27, 2018 in Tableau by Atul
• 10,240 points
9,944 views
0 votes
1 answer

How can I use Tableau to create a heatmap?

Step 1: Create an Excel Spreadsheet with ...READ MORE

answered Apr 2, 2018 in Tableau by ffdfd
• 5,550 points
2,937 views
0 votes
1 answer

How to group bins in a tableau histogram?

One of the simple way is by ...READ MORE

answered Apr 3, 2018 in Tableau by xyz
• 1,560 points
6,900 views
0 votes
2 answers
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 7, 2019 in Python by Neha
• 330 points

edited Jul 8, 2019 by Kalgi 4,464 views
0 votes
1 answer
0 votes
1 answer

How to fix spelling error in a field or column value using Tableau?

You should be able to use a ...READ MORE

answered Mar 10, 2022 in Tableau by Neha
• 9,020 points
780 views
0 votes
1 answer

How to adjust center axis width in a butterfly chart in Tableau

Concatenated by Dashboard Instead of using a single ...READ MORE

answered Mar 29, 2022 in Tableau by Neha
• 9,020 points
1,017 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP