How can I create a filled map with custom polygons in Tableau given point data? - tableau-api

In one TDE, I have individual posts from a hyperlocal social network with lat/long data. In the other TDE, I have polygons for Chicago's community areas.
How can I shade those community areas according to the number of records that were posted within its boundaries?
I'd like to essentially look up the community area by lat/long since I don't have the community area data within the first TDE to perform a join. Is there some other way to generate these shaded polygons given the data I already have? Is there another mapping tool that could do this for less than hundreds of dollars, if Tableau is not the answer?
Here's my workbook on Tableau Public.

You could load both data sets into Postgres. Add the PostGIS extension, so you can do geospatial queries to map posts to polygons. The connect Tableau to Postgres to create your visualization. One step at a time.

Related

Calculate areas of new features in merged layer in QGIS

I have merged four different layers into one new one in QGIS, but I want this layer to have different information then the old layers. I want all the buffered 'islands' to have a different ID and a calculated area. However, now in the attribute table I just see four features, one for each layer that I merged. Is there a way to update the attribute table to consist of new features (one for each 'island')?
This is what the layer looks like:
And this is what the attribute table now looks like:
And this is what I want (the 5th and 6th column especially):
You must create a feature for each monopart geometry, you can achieve this using the 25.1.18.46. Multipart to singleparts tool, and then use the field calculator to get the area, you can find here how to calculate area Calculating polygon areas in shapefile using QGIS.

which is an alternate chart for sankey diagram in tableau

I have been trying to visualise a sequence chart(flow) in tableau using sankey chart. is there any workaround for sankey? if there is an workaround suggest a good visualisation.
You can use heatmaps with source/ target in rows and columns and the flow value be represented in the cell.
Alternatively, you can stick with tableau for sankeys. I have done that and it adds immense value to develop overall storyline.

How to pickup a shape based on a cell text in tableau reports

I am not a tableau developer but i am just a user of tableau reports. My engineer is telling something is not possible so wanted to take experts suggestions and help to solve the problem.
My requirement is simple. We need to build a report in tableau with 4 columns and the last column should contain a color coded arrows (R,G,Y) representing the data trend (Up/Continuous/Down). The data will change frequently and the input source is excel sheet. My engineer is suggesting that, everytime we have to manually set those shapes in the 4th column, once the report is generated from the excel (basically from the first 3 columns only). I dont like to have a manual intervention everytime in tableau since i am not good at building/editing reports and its not a best practice to automate something.
In below picture the last column is the one i wanted to automatically generated based on excel sheets data.
My suggestion to him is to add the 4 column with data as below and in tableau bring the shapes accrodingly using some kind of a formula or so.
GC = Green continuous
GU = Green upwards trend
GD = Green downwards trend.. followed with different color codes (Green/Red/Yellow) as per data.
Is that possible in Tableau? If so any suggestions here would be greatly appreciated.
Thanks,
Kiran
It is definitely possible, as long as you have a formula that can produce the GC, GU, etc. values. Then it is simply a matter of mapping your custom values to relevant shapes (which is a simple manual one-off step in Tableau). If built-in shapes are not sufficient, you can add custom ones. Some types of shapes can also be colored dynamically, based on another formula.
Use Tableau Help or Google/Tableau Forum to find out how to do all of this.

Postgres spatial index for LAB colours?

I have a Postgres database containing photographs and I want to let people search them by colour. I already have multiple colours (1-5) defined for each photograph, and I'm using LAB colours (perceptual colour space, defined in three dimensions: lightness plus two colour dimensions).
My question is: what is the best way to do this in Postgres? It's essentially a three-dimensional search, so should I use a spatial index?
My requirements are:
run a bounding box search by colour (find photos with colours within distance X of colour Y).
rank results by distance from colour X (return photos with colours closest to colour Y first)
r-tree-like performance.
I've built a proof-of-concept using an rtree index in Python, and it's working pretty well. I'm just not sure how to replicate it using Postgres tables.
I see a couple of options. PostGIS has multi-dimensional geometry types which may give exactly what you are looking for. You could do bounding boxes over 3d points, for example. That would be easiest.
PostGIS is a Geospacial add-on but it can be used for a large number of other things too. What you are looking at doing is spacial even if not GIS and this may be the best tool for the job. PostGIS would handle all your indexing needs also including distance searches and the like.
If this is not acceptable you could write your own types. You'd probably want to write GiST operators as well for them and there is a fairly large learning curve there.

Extract open street map data for a specific region

I have openstreet data for a specific state. Now I want to extract the data for a city in that city. What sort of tools are available for that?
There are several tools for extracting a region from a file with OpenStreetMap data. Popular options are
Osmosis - see the wiki page's "Example Usage" section for examples of extracting bounding boxes and polygon areas
Osmconvert - see the "Clipping based on Longitude and Latitude" and "Clipping based on a Polygon" sections
In both cases you need to create or obtain a file containing the city's boundary if you want to accurately extract a polygon area.
You could also try the following web site which is very good at extracting information from open street maps it's the xapi
http://overpass-turbo.eu/
I found it to be good and quick and you can define an area to be searched i.e resizing the boundary box and you can export your retrieved data.