I have some cities' population data (number) and urban area (sq.m.) of 3 consecutive years (1991,2001&2011). I want to get the patterns of urbanization of those cities.
Could anyone suggest how to do that using depth & standards methods?
I have some point data that has kilometers from the specific point of the road. I want to extract the lat and long. How could it be done?
You will not be able to get a precise set of Lat/Long, unless there is more detail in the data recorded at the police station.
One solution might be to buffer the police station to 1 km then select all the road sections within the 1 km buffer. If the police data holds the road name or ID you could then link your accident to the road section identified in the buffer. Theoretically you could then take the center point along the road, however this would be misleading as if you create a map of this it will create a false impression of where accidents occur.
I would like to create a fairly big (~1bln nodes) weighted graph, with nodes being locations and edges being the roads that are present in OpenStreetMap data. Let us say we want to focus on some country, to keep the size within the above limit. The weights of the edges can be the actual lengths of the roads they represent. What would you do? Should I write my own parser for XML data and construct it in a straightforward way?
You may find gis.stackoverflow.com useful. The keywords are PostGIS and pgRouting. See e.g. https://gis.stackexchange.com/questions/21680/collecting-street-data-to-populate-a-graph-stucture-for-routing/21682#21682
and similar questions.
Now I'm trying to overlay latitude and longitudinal points from two different data sets, resulting in two different markers for each one on a geographical map. There is no relationship between the two data sets. Tableau doesn't seem to be able to accomplish this directly. I don't want to group the data at all, just plot the lat and lon points. Any suggestions?
I would also like one of the datasets above to be a heatmap, i.e. each data point plotted has its intensity correlated to the dimension. Besides the overlaying problem above, accomplishing a geographical heat map alone is not working for me. My geographical heat map by latitude and longitudinal points is not conveying the information I want. The lighter color marks are on top of the darker color marks. However, I want the darker color marks to be in front. How do I achieve this?
Would Google Maps or Fusion Tables be a better option for me?
I solved this problem by combining the two datasets into one using UNION ALL, making sure to add an extra column with a descriptor designating the originating source (i.e., which of the two datasets). I then set up a calculated field to determine what data to visualize and how to visualize it.
As regards to the heatmap, the solution was to bin the data and then sort it when plotting. Without binning, sorting appears not possible using Tableau.
I took a look at Google Maps and Fusion Tables, but the functionality and visual aesthetics are currently not at the Tableau level.
I want my users to be able to specify their locations so that I can plot them on a map. Given an address, I use Google Maps API to get their lat/long coordinates and store that in the database.
Additionally, I want to allow users to search for other users based on location. Using Google Maps API, I can also get, say, country/state/city for address (or lat/long coordinates). My problem is that I don't know how to store country/state/city in such a way that:
The data is associated to a particular user
There is no data redundancy
The problem I think is if User-1 and User-2 both enter an address that results in the country being "USA", I think I need to know that User-1 and User-2 are both from the USA -- AND that "USA" is only stored once in the DB.
When users search for other users, I think I should only let them search for users in the USA if I actually have users from USA. Meaning, assume User-1 and User-2 are the only 2 users from the USA, if User-1 and User-2 delete their profiles, I shouldn't allow searches for users in the USA anymore.
Are my ideas conceptually wrong? In any case, how should I model this information? I'm using MySQL.
Your goals and intentions are correct (don't give them up!), you may need a bit of help getting over the line, that's all. The more understanding and experience you have with data modelling and Normalisation, the easier it will be. So do as much research and exercise as you can (SO or the web is not a good way to learn anything).
For loading and maintenance purposes, you are better off ensuring that you have a normalised, top-down structure for geographic locations. You can load it from info provided (usually free) by your council or county or Post Office or whatever. That will eliminate manual data entry for the External Reference tables.
This is a highly Normalised Data Model, at 5NF.
But there's more Normalisation that can be done; more duplication that can be removed. It is not worth it unless you are really interested, eg. you need to search on LastNames, etc.
.
This one is for an Utility company, to ensure that false Street locations are not provided by the prospective customers.
Address is a specific house or unit (apartment), and that it not duplicated. Two People living at the same address will use one Address row.
This structure handles "any" geographic location. Note that some countries do not have State; some States do not have Counties; some Towns do not have Suburbs; etc. Rather than building all those exceptions into the Data Model, I have kept the hierarchy "clean". You will still need to handle that in your SQL (whether or not the model is simple with no exceptions, or whether it has exceptions; because that is the real world), and not display the State for a State-less Country. All you need is a row for the non-State with a StateCode of CHAR(0) that identifies the condition.
I have placed Longitude & Latitude at the Suburb level, assuming that that is what your users can choose easily via GoogleMaps, and because Street level will have limitation (might be to fine grained, and would cause duplication; or not fine grained enough for cities with very long Streets). Easy to change.
For now, I suggest you do not worry about identifying users in the same country, first see if you can handle the SQL to identify users in the same Suburb (not Street, that is easy). After that, we can deal with City, County, Country, etc.
I think the other searches you identify are effortless; see if you agree.
Anyway, this is just something to get you started; there is some interaction to be had before it is finalised.
Link to GLS Data Model (plus the answer to your other question)
Link to IDEF1X Notation for those who are unfamiliar with the Relational Modelling Standard.