RJ Duran
MAT259 Winter 2012
Data Visualization
Project 2
Introduction
The goal of this project is to utilize a bi-variate spatial map to visualize data answering the question: How “Green” is Seattle?
The inspiration for this question came from a genuine interest to understand how knowledgeable the general library going population of Seattle is when it comes to topics of sustainability, pollution, health and wellness, conservation, social issues, economic issues, and politics. I feel that this is an important question to address because the general public needs to have an understanding of what’s happening locally and globally today.
Through the library data I tried to illustrate the reading habits of people based on the number of checkouts per hour per day within 7 categories: Conservation, Economic, Political, Social, Sustainability, Science, and Technology. By grouping titles into these categories I was able to make sense of the large amount of information.
Technically the project involved one query to search for titles within a set list of keywords and filter out the desirable titles from the undesirable. I then looked through each month displayed and counted the total books marked with a specific category for each hour of each day. While this approach produces some interesting results, there is still some error in the counting and data requested itself. Mainly, duplicate entries and marking items for more than one category.
There is a simple amount of interaction to allow the user to navigate through the data for each month within 2011 shown in the bottom left. The mouse was used to provide basic hover functionality showing the total checkouts per day for a given hour. A secondary color palette was also implemented to show dark and light palettes. I used a simple grid to do the layout of elements. The code itself is a little crude since we had somewhat of a short time frame to implement a design but I tried to keep things organized.
Sketch
Query
This is the query used for collecting information.
keyword = keywords used to search for in titles and subjects
category-keyword = keywords used to classify items into categories based on title and subject
ignore-keywords = keywords to ignore in titles and subjects
SELECT date(cout), time(cout), title,
IF(title like '%category-keyword%' or..., '1', '0') as cat1,
IF(title like '%category-keyword%' or…, '1', '0') as cat2,
IF(title like '%category-keyword%' or…, '1', '0') as cat3,
IF(title like '%category-keyword%' or…, '1', '0') as cat4,
IF(title like '%category-keyword%' or…, '1', '0') as cat5,
IF(title like '%category-keyword%' or…, '1', '0') as cat6,
IF(title like '%category-keyword%' or…, '1', '0') as cat7
FROM inraw WHERE (year(cout) = '2011' AND month(cout) > 0 AND month(cout) < 13)
AND ((title like '%keyword%' or...) AND NOT (title like '%ignore-keyword%' or...)
AND (subj like '%keyword%' or...) AND NOT (subj like '%ignore-keyword%' or...))
AND (itemtype = 'acbk' or itemtype = 'arbk' or itemtype = 'acper' or itemtype = 'arper' or itemtype = 'arnp')
ORDER BY date(cout) ASC, hour(cout) ASC;
Reference
http://rjduran.net/MAT/259/project2/p2_query.txt
http://rjduran.net/MAT/259/project2/p2_keywords.txt
http://rjduran.net/MAT/259/project2/p2_ ... ywords.txt
http://rjduran.net/MAT/259/project2/p2_ ... ywords.txt
Result
http://rjduran.net/MAT/259/project2/gre ... l-0223.png (Permanent)
http://rjduran.net/MAT/259/project2/gre ... l-0364.png (Permanent)
Code
http://rjduran.net/MAT/259/project2/gre ... _final.zip (Permanent)