• I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    *It’s often easier to solve many D3 problems going straight to documentation, at least for the use cases I’ve been working on, than Googling. Get in the habit of knowing if you need to look at Scale documentation for instance and getting more comfortable with that.

    Coding Learning:

    Introducing D3 Scale 

    Three Takeaways

    • Remember conceptually “a scale is a function that takes an abstract value of data, such as the mass of a diamond in carats, and returns a visual value such as the horizontal position of a dot in pixels. D3’s quantitative scales are functions configured by two intervals. The input domain is an interval in the abstract dimension of data, often the extent of the observed values. The output range is an interval in the visual variable, such as the visible area defined by the chart size.”
    • There are scales for ordinal and categorical data. The band scale, for instance, simplifies the calculation of bar widths and positions, allowing configurable padding, alignment and rounding.
    • Scales can interpolate symbol sizes, font sizes, stroke widths, colors in various color spaces, geometric transforms, shapes and even deeply-nested objects.

      Parsing Raw Data from PGBovine

    Three Takeaways

    • “The most important tip: assert the hell out of your parsing code. Write down every assumption you have about the data’s format in the form of assertions, then revise those assertions as you find out which parts of the data inevitably violate them.” Follow this later with a verifier program to check integrity of cleaned data.
    • Use sets or counter data structure to store the occurrences of categorical variables.
    • Have program print to see where parsing failed and to be able to pass a parameter to specify a starting point so you don’t have to restart at beginning.

    Reading and Learning Data Visualization Theoretically/Critically:

    The Functional Art: An Introduction to Information Graphics and Visualization by Alberto Cairo

    p 114-123 – Visualizing for the Mind

    Three Takeaways

    • Proximity in Gestalt Principles “notes that objects that are close to each other tend to be perceived as natural groups.”  “Identical objects as well will be perceived as belonging to a group”p. 114-115
    • “Continuity is better perceived in curves than in lines with sharp angles.” p 117
    • On a note when deploying perceptual tasks (in order of accuracy Position along common scale, position along nonaligned scales, “Length, Direction, Angle, Area, Volume, Curvature, Shading, Color Saturation” p 120): “The important criterion for a graph is not simply how fast we can see a result; rather it is whether through the use of the graph we can see something that would have been harder to see otherwise or that could not have been seen at all” p 123
  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    Reading and Learning Data Visualization Theoretically/Critically:

    The Functional Art: An Introduction to Information Graphics and Visualization by Alberto Cairo

    p 105-114 Visualizing for the Mind

    Three Takeaways

    • Remember that “what your retina gets is not what your brain preceives.  In fact, what we commonly call seeing is not a single phenomenon, but a group at least three operations: sight, perception, and cognition.” p 109
    • “The brain is much better at quickly detecting shade variations than shape differences” p 113
    • Three important objects your brain preattentively detects is size, orientation, and color/shade. p 114
  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    The Functional Art: An Introduction to Information Graphics and Visualization by Alberto Cairo

    p 86-105 The Beauty Paradox: Art and Communication-> The Complexity Challenge: Presentation and Exploration

    Three Takeaways

    • “Emotion and cognition are thoroughly intertwined… Beauty and functionality are intertwined, or should be” p 87
    • “Seeing, perceiving, and knowing are different phenomena.” p 98
    • Thinking about cognition, how the brain prioritizes visual phenomena is important as a design principle.  Much of response is unconscious.
      • eg. Because of the “eye-brain system’s attraction to moving objects and uncommon shapes, you should never simultaneously show an animation of the robot on the right side of the screen and a text box on the left” p 105
  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    Code Learning:

    Udacity Data Visualization and D3.js – DimpleJS and Narrative Structures Lectures

    Three Takeaways

    • Start sharing and responding to graphics ASAP
    • Anonymous accessor function because it allows to change the behavior of a generic D3 function, eg extent to act differently below depending what we return
    var count_extent = d3.extent(data, function(d) { return d['attendance]};
    var time_extent = d3.extent(data, function(d) {return d['date']};
    • Traditional journalism was around data around narrative, and data journalism is narrative around data.
      • Linear versus complex structures with data-driven storytelling
  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    Code Learning:

    Udacity Data Visualization and D3.js – DimpleJS Lectures

    Three Takeaways

    • You can interact with DimpeJs with CSS, D3, and Javascript:
      • Inspect elements using developer console to find classes or ids to change styling for example for CSS
      • Put in  d3 directly: d3.select(“body”).append(“h2”).text(“World Cup Attendance”);
    • When choosing a chart type, consider the overall message you are trying to convey, the data types of the variables, and the relationships you want readers to explore
    • Think about the subconscious process in which people perceive objects  without any conscious effort (preattentive processing) in contrast to “attentive” processing or conscious processing when thinking about encoding visuals or especially when calling out important points
  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    *Back on the wagon after some well needed X-mas R&R.  Will be off it for NY weekend probably.  I can forgive myself for needed rest and complete mind wipe.

    Visual Created:

    Dimple JS Scatterplot using NYCFC Data

    Screen Shot 2015-12-27 at 9.05.22 PM.png

    Code Learning:

    Treehouse Back to Basics – Front-End Dev

    Udacity Data Visualization and D3.js – DimpleJS Lectures

    Three Takeaways

    • Don’t forget to use auto-fill in console, eg typing myChart.add to see other methods.  This can be more expedient than looking through documentation.
    • Faceting data versus not and changing type of chart:
    myChart.addSeries(null, dimple.plot.bar); // not faceting or grouping data, eg just showing all data
    myChart.addSeries('stage', dimple.plot.bar); // groups data, eg showing stages versus all games in this example data of soccer games
    myChart.addSeries(null, dimple.plot.scatter) // makes a scatterchart instead of a bar chart
    myChart.addSeries(null, dimple.plot.line);  // makes a line chart
    
    You can combine series by including two series, eg both lines above to have points on the time series
    • Way to parse date in Dimplejs or other ways to easily manipulate properties
    x.dateParseFormat = "%Y";
    x.timeInterval = 4;
    x.ticketFormat = "%Y";
  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    *Reading for these last precious few days before taking off for Christmas – where I’ll finish the Udacity course

    Code Learning:

    Learn JS Data Regular Expressions

    • Replacing with Regular Expressions
      • Example of replacing “wood” with the word “nun.”
    var str = “how much wood would a woodchuck chuck if a woodchuck could chuck wood”;
    var regex = /wood/g;
    var newstr = str.replace(regex), “nun”
    
    console.log(newstr);
    
    => “How much nun would a nunchuck chuck if a nunchuck could chuck nun”

    Finding Numbers

    • Extracting money from groceries as an example.  You’d need to define a regular expression that defines a patterns, for example in the below
    • Dollar sign as (\$) to indicate beginning of a price
    • Set of repeating characters than can be 0-9 or period(.) We denote these care appear repeatedly (+).
    • Word break to indicate end of the price string (\b)
    var message = “I bought a loaf of bread for $3.99, some milk for $2.49 and” + “a box of chocolate cookies for $6.95”;
    regex = /\$([0-9\.]+)\b/g;
    matches = message.match(regex)console.log(matches);
    
    =>  [“$3.99”, “$2.49”, “$6.95”]
    • Since we can’t add with $ signs, reduce!
    matches.reduce(function(sum, value) {
    return sum + Number(value.slice(1));
    }, 0);
    
    =>13.43
    • Using special characters
      • \d – any number character, equivalent to [0-9]
      • \D – any nonnumber character, equivalent to [^0-9]
      • \s – any single space character.  This includes a single space, tab, line feed or form feed.

     

     

  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    *Reading for these last precious few days before taking off for Christmas – where I’ll finish the Udacity course

    Reading and Learning Data Visualization Theoretically/Critically:

    The Functional Art: An Introduction to Information Graphics and Visualization by Alberto Cairo

    p 76-85 The Beauty Paradox: Art and Communication-> The Complexity Challenge: Presentation and Exploration

    Three Takeaways

    • In many cases now “the designer is no longer just a designer.  He has begun to think and act as a software engineer.” p 76
    • “Graphics should not simplify messages.  They should clarify them, highlight trends, uncover patterns, and reveal realities not visible before.” p79
    • “The less common the graphic form I choose for my visualization, the more redundancy I should include.” p85
  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    *Doing a bit of catch-up here after a few breaks.

    Reading and Learning Data Visualization Theoretically/Critically:

    The Functional Art: An Introduction to Information Graphics and Visualization by Alberto Cairo

    p 65-76 The Beauty Paradox: Art and Communication-> The Complexity Challenge: Presentation and Exploration

    Three Takeaways

    • “Tufte’s influence in the visualization and information graphics communities has led many publications to adopt a style that is serious, cold, and stripped bare of aesthetic attributes that maybe gratuitous to the statistician but useful for readers” p 68
    • “The first step to finding the middle ground between radical minimalism and a more playful approach to information graphics and visualization is to remember that a good graphic realizes two basic goals: It presents information, and it allows users to explore that information.” p 73
    • “No matter what style you choose- whether you decide to follow Tufte and become a hardcore minimalist or adopt a friendlier approach- always take advantage of the space you have available to seek depth within reasonable limits.  After that, and only after that, worry about how to make the presentation prettier.” p 76
  • I’m doing some form of data visualization learning for 180 days because I need to #JFDI.

    See post explaining how and why I’m doing this.

    *Doing a bit of catch-up here after a few breaks.

    *Also quick note of reflection here, the more I’ve practice doing data viz in the wild for clients and the more I read, the more my opinions have changed about topics like chart junk and dumbing down visuals for audiences.  Yes, sometimes I think I just am making pitch candy to provide flash for clients.  However, in real life, aesthetics matter and hoping for immediate understanding for your audience maybe unrealistic.  That’s why there are consulting and account management layers in business.  I use to be a part of that machine which is why I was hired to do this type of work now because I understand the business end more intimately more than a graphic artist or a data scientist might.

    Reading and Learning Data Visualization Theoretically/Critically:

    The Functional Art: An Introduction to Information Graphics and Visualization by Alberto Cairo

    p 61-65 The Beauty Paradox: Art and Communication

    Three Takeaways

    • Engineers vs Designers: There’s always been a flash between those who emphasize functionality to those who place more emphasis on emotions and aesthetics. p 61
    • “Tufte’s principle of efficiency: A visual design project is good if it communicates a lot with a little.” p 63
    • Tufte’s “assertion that a higher efficiency- the lowest amount of visual resources to communicate the highest possible amount of content- always facilitates understanding is dubious.” p 65