SlideShare a Scribd company logo
VISUALIZATIONS WITH
    SPARQL AND
     VISUALBOX
      Alvaro Graves
      @alvarograves
      gravea@rpi.edu
MOTIVATION
Linked Data brings tons of multidimensional data that
is easy(*) to query
However, having to make use of all that data we still
need to being able to process it (as humans)
One good way to make sense of this data is by using
visualizations


                                       (*) Once you learn SPARQL
EXAMPLE

                                                                               versus




Images: Few, Stephen (2010): Data Visualization for Human Perception. In: Soegaard, Mads and Dam, Rikke Friis (eds.). "Encyclopedia of Human-Computer Interaction". Aarhus, Denmark:
                The Interaction Design Foundation. Available online at http://www.interaction-design.org/encyclopedia/data_visualization_for_human_perception.html
VISUALBOX
Based on LODSPeaKr
Make use of new and already existing visualization
filters
Creating of visualization via new GUI
Principle: Good data representation leads to good/easy
data manipulation
  Corolary: Effort should be focused on obtaining the
  right data
VISUALBOX
MODELS (SPARQL QUERY)
 Using the SELECT query form will return a table, similar
                       to SQL.
main.query


        PREFIX foaf: <http://xmlns.com/foaf/0.1/>

        SELECT ?person1 ?person2 WHERE{
          ?person1 foaf:knows ?person2 .
        }




    person1                                         person2
    http://example.org/john                         http://example.org/paul
    http://example.org/john                         http://example.org/ringo
    http://example.org/george                       http://example.org/paul
VIEWS (TEMPLATES)
                We can decide how to operate with the data.
html.template

<ul>
{{for row in models.main}}
 <li>{{row.person1.value}} knows {{row.person2.value}}</li>
{{endfor}}
</ul>

output



  http://example.org/john knows http://example.org/paul




  http://example.org/john knows http://example.org/ringo




  http://example.org/george knows http://example.org/paul
FILTERS
                   It is possible to apply filters to the data.
Template


{{for row in models.main}}
  {{row.person1.value|upper}}
{{endfor}}


Output

HTTP://EXAMPLE.ORG/JOHN
HTTP://EXAMPLE.ORG/JOHN
HTTP://EXAMPLE.ORG/GEORGE
VISUALIZATION FILTERS
   It is possible to apply visualization filters directly to all
    the results. These filters will generate the necessary
                 code to create a visualization
Model (main.query)

PREFIX cat: <http://dbpedia.org/resource/Category:>

SELECT ?countryLabel (COUNT(?nobel) as ?total) WHERE {
 ?nobel dcterms:subject cat:Nobel_laureates_in_Physics;
        a foaf:Person;
        dbp:placeOfBirth ?country .

 ?country a schema:Country ;
          rdfs:label ?countryLabel
          FILTER(LANG(?countryLabel) = "en")
}GROUP BY ?country ?countryLabel
ORDER BY DESC(?total)
LIMIT 100
countryLabel      total
United States     23
Germany           14
England           9
Japan             6
Austria-Hungary   5
France            5
Netherlands       4
German Empire     3
Soviet Union      3
United Kingdom    3
Italy             3
View (html.template)

<body>
   <h2>Total of Nobel laureates in Physics by country</h2>
   {{models.main|GoogleVizPieChart:"countryLabel,total"}}
</body>
TABULAR DATA
         Easiest case: consider table-based visualizations.
View (html.template)

{{models.main|GoogleVizColumnChart:"countryLabel,total"}}
View (html.template)

{{models.main|GoogleVizBarChart:"countryLabel,total"}}
View (html.template)

{{models.main|GoogleVizLineChart:"countryLabel,total"}}
MAPS
 Represent data as latitude, longitude and label


SELECT DISTINCT ?city SAMPLE(?lat) AS ?latitude SAMPLE(?long) AS ?longitude ?area WHERE{
 ?city a sch:City ;
       <http://dbpedia.org/ontology/country> <http://dbpedia.org/resource/United_States> ;
       geo:lat ?lat ;
       geo:long ?long;
       dbp:areaTotalKm ?area .

}GROUP BY ?city ?area
ORDER BY DESC(?area)
LIMIT 10
latitude longitude area
45.4983 -91.7389 25.0
30.3167 -81.6667 2292
45.9989 -112.53 1868
View (html.template)

{{models.main|GoogleMaps:"latitude,longitude,area,width=800"}}
PARALLEL COORDINATES
Query

SELECT ?carLabel ?wheelbase ?carWidth ?carLength ?transmission WHERE {
 ?car dcterms:subject <http://dbpedia.org/resource/Category:Lamborghini_vehicles>;
      <http://dbpedia.org/ontology/Automobile/wheelbase> ?wheelbase;
      <http://dbpedia.org/ontology/MeanOfTransportation/height> ?carWidth;
      <http://dbpedia.org/ontology/MeanOfTransportation/length> ?carLength;
      <http://dbpedia.org/property/transmission> ?transmission;
      rdfs:label ?carLabel.
  FILTER(LANG(?carLabel) = "en")
}
PARALLEL COORDINATES
           carLabel                           wheelbase carWidth carLength transmission
           Lamborghini Aventador 2700.0                        1136.0          4780.0        7
           Lamborghini Reventón 2665.0                         1135.0          4700.0        6
           Lamborghini 400GT                  2550.0           1257.0          4470.0        5
Template


{{models.main|D3ParallelCoordinates:"carLabel,wheelbase,carWidth,carLength,transmission"}}
PARALLEL COORDINATES
GRAPHS
              Question: How to express a graph in a table?
                  Answer: Table child → parent
Model (main.query)

SELECT ?person1 ?person2 WHERE{
  ?person1 foaf:knows ?person2 .
}



                                   person1           person2
                                   Elizabeth Engstrom Ray Bradbury
                                   Neil Gaiman       Robert A. Heinlein
                                   Neil Gaiman       Ray Bradbury
View (html.template)

  {{models.main|D3ForceGraph:"person1,person2"}}
TREE STRUCTURES
Problem: How do we retrieve a tree as a table?
Solution (so far): Table child,parent with one row with no
parent (root)
         child                          parent                      area

         Averill Park, New York         Rensselaer County, New York 8.02896e+06

         Sand Lake, New York            Rensselaer County, New York 9.36e+07

         Schaghticoke (town), New York Rensselaer County, New York 1.3442e+08

         Poestenkill (town), New York   Rensselaer County, New York 8.44336e+07

         Schaghticoke (village), New York Rensselaer County, New York 2.33099e+06

         Rensselaer County, New York
TREE STRUCTURES
Query

PREFIX d: <http://dbpedia.org/ontology/>
SELECT max(?regionLabel) as ?child max(?superregionLabel) as ?parent (max(?totalArea) as ?area) WHERE{
  {
  ?region d:isPartOf <http://dbpedia.org/resource/Rensselaer_County,_New_York>;
     d:areaTotal ?totalArea ;
     rdfs:label ?regionLabel;
     d:isPartOf ?superregion .
    ?superregion rdfs:label ?superregionLabel.
    FILTER(?superregion = <http://dbpedia.org/resource/Rensselaer_County,_New_York>)
    FILTER(lang(?superregionLabel) = "en")
  }UNION{
    ?region rdfs:label ?regionLabel .
    FILTER(?region = <http://dbpedia.org/resource/Rensselaer_County,_New_York>)
  }
FILTER(lang(?regionLabel) = "en")
}GROUP BY ?regionLabel ?superregionLabel


Template

{{models.main|D3CirclePacking:"child,parent,area"}}
Visualizations using Visualbox
TREE STRUCTURES (2)
Query (neruda.query)

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX dbp:       <http://dbpedia.org/ontology/>
PREFIX d: <http://dbpedia.org/resource/>
SELECT DISTINCT ?child ?parent WHERE{
    {
        ?childNode dbp:influencedBy ?mid ;
                    rdfs:label ?child .
        ?mid dbp:influencedBy ?parentNode;
              rdfs:label ?parent .
        FILTER(LANG(?parent) = "en" && ?parentNode = d:Pablo_Neruda)
    }UNION{
        ?childNode dbp:influencedBy d:Pablo_Neruda;
                    dbp:influencedBy ?parentNode;
                    rdfs:label ?child .
        ?parentNode rdfs:label ?parent .
        FILTER(LANG(?parent) = "en" && ?parentNode = d:Pablo_Neruda)
    }UNION{
        d:Pablo_Neruda rdfs:label ?child
    }
    FILTER(LANG(?child) = "en")
}
child              parent

                                        Pablo Neruda

                                        Dane Zajc          Pablo Neruda

                                        Gary Soto          Pablo Neruda

                                        James Tate (writer) Pablo Neruda

                                        Richard Aitson     Pablo Neruda

                                        Erin Siegal        Pablo Neruda

                                        Jože Snoj          Dane Zajc

                                        Rudi Šeligo        Dane Zajc

                                        Veno Taufer        Dane Zajc

                                        Rigoberto González Gary Soto

                                        Thomas Lux         James Tate (writer)

html.template

{{models.main|D3Dendrogram:"child,parent"}}
TREE STRUCTURES (2)
NOW YOU CREATE YOUR OWN
            VISUALIZATION
Use data that is of interest for you
Describe to tell a story or support a statement
Give me feedback on how does visualbox works for
you

More Related Content

Viewers also liked (8)

Datos malos, robots tristes
Datos malos, robots tristesDatos malos, robots tristes
Datos malos, robots tristes
Alvaro Graves
 
Data Tuesday
Data TuesdayData Tuesday
Data Tuesday
Alvaro Graves
 
Towards a better understanding of Social Machines
Towards a better understanding of Social MachinesTowards a better understanding of Social Machines
Towards a better understanding of Social Machines
Alvaro Graves
 
Publishing Linked Data with LODSPeaKr
Publishing Linked Data with LODSPeaKrPublishing Linked Data with LODSPeaKr
Publishing Linked Data with LODSPeaKr
Alvaro Graves
 
Integrating and publishing public safety data using semantic technologies
Integrating and publishing public safety data using semantic technologiesIntegrating and publishing public safety data using semantic technologies
Integrating and publishing public safety data using semantic technologies
Alvaro Graves
 
Como crear aplicaciones basadas en linked data usando lods pea kr
Como crear aplicaciones basadas en linked data usando lods pea krComo crear aplicaciones basadas en linked data usando lods pea kr
Como crear aplicaciones basadas en linked data usando lods pea kr
Alvaro Graves
 
Creating visualizations using Linked Data
Creating visualizations using Linked DataCreating visualizations using Linked Data
Creating visualizations using Linked Data
Alvaro Graves
 
Querying Linked Data on Android
Querying Linked Data on AndroidQuerying Linked Data on Android
Querying Linked Data on Android
EUCLID project
 
Datos malos, robots tristes
Datos malos, robots tristesDatos malos, robots tristes
Datos malos, robots tristes
Alvaro Graves
 
Towards a better understanding of Social Machines
Towards a better understanding of Social MachinesTowards a better understanding of Social Machines
Towards a better understanding of Social Machines
Alvaro Graves
 
Publishing Linked Data with LODSPeaKr
Publishing Linked Data with LODSPeaKrPublishing Linked Data with LODSPeaKr
Publishing Linked Data with LODSPeaKr
Alvaro Graves
 
Integrating and publishing public safety data using semantic technologies
Integrating and publishing public safety data using semantic technologiesIntegrating and publishing public safety data using semantic technologies
Integrating and publishing public safety data using semantic technologies
Alvaro Graves
 
Como crear aplicaciones basadas en linked data usando lods pea kr
Como crear aplicaciones basadas en linked data usando lods pea krComo crear aplicaciones basadas en linked data usando lods pea kr
Como crear aplicaciones basadas en linked data usando lods pea kr
Alvaro Graves
 
Creating visualizations using Linked Data
Creating visualizations using Linked DataCreating visualizations using Linked Data
Creating visualizations using Linked Data
Alvaro Graves
 
Querying Linked Data on Android
Querying Linked Data on AndroidQuerying Linked Data on Android
Querying Linked Data on Android
EUCLID project
 

Similar to Visualizations using Visualbox (20)

Introduction to Graph Databases
Introduction to Graph DatabasesIntroduction to Graph Databases
Introduction to Graph Databases
Max De Marzi
 
Exploring the Semantic Web
Exploring the Semantic WebExploring the Semantic Web
Exploring the Semantic Web
Roberto García
 
Linked Open Data for Digital Humanities
Linked Open Data for Digital HumanitiesLinked Open Data for Digital Humanities
Linked Open Data for Digital Humanities
Christophe Guéret
 
Place graphs are the new social graphs
Place graphs are the new social graphsPlace graphs are the new social graphs
Place graphs are the new social graphs
Matt Biddulph
 
Seminario Cristian Lai, 06-09-2012
Seminario Cristian Lai, 06-09-2012Seminario Cristian Lai, 06-09-2012
Seminario Cristian Lai, 06-09-2012
CRS4 Research Center in Sardinia
 
Choices, modelling and Frankenstein Ontologies
Choices, modelling and Frankenstein OntologiesChoices, modelling and Frankenstein Ontologies
Choices, modelling and Frankenstein Ontologies
benosteen
 
Session 3 "Challenges and Opportunities with Big Linked Data Visualization" t...
Session 3 "Challenges and Opportunities with Big Linked Data Visualization" t...Session 3 "Challenges and Opportunities with Big Linked Data Visualization" t...
Session 3 "Challenges and Opportunities with Big Linked Data Visualization" t...
Laura Po
 
Graph Databases in Python (PyCon Canada 2012)
Graph Databases in Python (PyCon Canada 2012)Graph Databases in Python (PyCon Canada 2012)
Graph Databases in Python (PyCon Canada 2012)
Javier de la Rosa
 
Structured Data Presentation
Structured Data PresentationStructured Data Presentation
Structured Data Presentation
Shawn Day
 
Presenting Your Digital Research
Presenting Your Digital ResearchPresenting Your Digital Research
Presenting Your Digital Research
Shawn Day
 
Provenance and Reuse of Open Data (PILOD 2.0 June 2014)
Provenance and Reuse of Open Data (PILOD 2.0 June 2014)Provenance and Reuse of Open Data (PILOD 2.0 June 2014)
Provenance and Reuse of Open Data (PILOD 2.0 June 2014)
Rinke Hoekstra
 
From text to entities: Information Extraction in the Era of Knowledge Graphs
From text to entities: Information Extraction in the Era of Knowledge GraphsFrom text to entities: Information Extraction in the Era of Knowledge Graphs
From text to entities: Information Extraction in the Era of Knowledge Graphs
GraphRM
 
Open data and linked data
Open data and linked dataOpen data and linked data
Open data and linked data
Marie Gustafsson Friberger
 
Linked Data in Learning Analytics Tools
Linked Data in Learning Analytics ToolsLinked Data in Learning Analytics Tools
Linked Data in Learning Analytics Tools
Mathieu d'Aquin
 
MPhil Lecture on Data Vis for Analysis
MPhil Lecture on Data Vis for AnalysisMPhil Lecture on Data Vis for Analysis
MPhil Lecture on Data Vis for Analysis
Shawn Day
 
NoSQL, Neo4J for Java Developers , OracleWeek-2012
NoSQL, Neo4J for Java Developers , OracleWeek-2012NoSQL, Neo4J for Java Developers , OracleWeek-2012
NoSQL, Neo4J for Java Developers , OracleWeek-2012
Eugene Hanikblum
 
Linked Open Data Utrecht University Library
Linked Open Data Utrecht University LibraryLinked Open Data Utrecht University Library
Linked Open Data Utrecht University Library
Ruben Schalk
 
Knowledge Graph Introduction
Knowledge Graph IntroductionKnowledge Graph Introduction
Knowledge Graph Introduction
Sören Auer
 
Network Mapping & Data Storytelling for Beginners
Network Mapping & Data Storytelling for BeginnersNetwork Mapping & Data Storytelling for Beginners
Network Mapping & Data Storytelling for Beginners
Renaud Clément
 
Neo4j spatial-nosql-frankfurt
Neo4j spatial-nosql-frankfurtNeo4j spatial-nosql-frankfurt
Neo4j spatial-nosql-frankfurt
Peter Neubauer
 
Introduction to Graph Databases
Introduction to Graph DatabasesIntroduction to Graph Databases
Introduction to Graph Databases
Max De Marzi
 
Exploring the Semantic Web
Exploring the Semantic WebExploring the Semantic Web
Exploring the Semantic Web
Roberto García
 
Linked Open Data for Digital Humanities
Linked Open Data for Digital HumanitiesLinked Open Data for Digital Humanities
Linked Open Data for Digital Humanities
Christophe Guéret
 
Place graphs are the new social graphs
Place graphs are the new social graphsPlace graphs are the new social graphs
Place graphs are the new social graphs
Matt Biddulph
 
Choices, modelling and Frankenstein Ontologies
Choices, modelling and Frankenstein OntologiesChoices, modelling and Frankenstein Ontologies
Choices, modelling and Frankenstein Ontologies
benosteen
 
Session 3 "Challenges and Opportunities with Big Linked Data Visualization" t...
Session 3 "Challenges and Opportunities with Big Linked Data Visualization" t...Session 3 "Challenges and Opportunities with Big Linked Data Visualization" t...
Session 3 "Challenges and Opportunities with Big Linked Data Visualization" t...
Laura Po
 
Graph Databases in Python (PyCon Canada 2012)
Graph Databases in Python (PyCon Canada 2012)Graph Databases in Python (PyCon Canada 2012)
Graph Databases in Python (PyCon Canada 2012)
Javier de la Rosa
 
Structured Data Presentation
Structured Data PresentationStructured Data Presentation
Structured Data Presentation
Shawn Day
 
Presenting Your Digital Research
Presenting Your Digital ResearchPresenting Your Digital Research
Presenting Your Digital Research
Shawn Day
 
Provenance and Reuse of Open Data (PILOD 2.0 June 2014)
Provenance and Reuse of Open Data (PILOD 2.0 June 2014)Provenance and Reuse of Open Data (PILOD 2.0 June 2014)
Provenance and Reuse of Open Data (PILOD 2.0 June 2014)
Rinke Hoekstra
 
From text to entities: Information Extraction in the Era of Knowledge Graphs
From text to entities: Information Extraction in the Era of Knowledge GraphsFrom text to entities: Information Extraction in the Era of Knowledge Graphs
From text to entities: Information Extraction in the Era of Knowledge Graphs
GraphRM
 
Linked Data in Learning Analytics Tools
Linked Data in Learning Analytics ToolsLinked Data in Learning Analytics Tools
Linked Data in Learning Analytics Tools
Mathieu d'Aquin
 
MPhil Lecture on Data Vis for Analysis
MPhil Lecture on Data Vis for AnalysisMPhil Lecture on Data Vis for Analysis
MPhil Lecture on Data Vis for Analysis
Shawn Day
 
NoSQL, Neo4J for Java Developers , OracleWeek-2012
NoSQL, Neo4J for Java Developers , OracleWeek-2012NoSQL, Neo4J for Java Developers , OracleWeek-2012
NoSQL, Neo4J for Java Developers , OracleWeek-2012
Eugene Hanikblum
 
Linked Open Data Utrecht University Library
Linked Open Data Utrecht University LibraryLinked Open Data Utrecht University Library
Linked Open Data Utrecht University Library
Ruben Schalk
 
Knowledge Graph Introduction
Knowledge Graph IntroductionKnowledge Graph Introduction
Knowledge Graph Introduction
Sören Auer
 
Network Mapping & Data Storytelling for Beginners
Network Mapping & Data Storytelling for BeginnersNetwork Mapping & Data Storytelling for Beginners
Network Mapping & Data Storytelling for Beginners
Renaud Clément
 
Neo4j spatial-nosql-frankfurt
Neo4j spatial-nosql-frankfurtNeo4j spatial-nosql-frankfurt
Neo4j spatial-nosql-frankfurt
Peter Neubauer
 

More from Alvaro Graves (11)

Democratizing Open Data
Democratizing Open DataDemocratizing Open Data
Democratizing Open Data
Alvaro Graves
 
Explotando la Web de Datos: Como crear aplicaciones usando Linked Open Data
Explotando la Web de Datos: Como crear aplicaciones usando Linked Open DataExplotando la Web de Datos: Como crear aplicaciones usando Linked Open Data
Explotando la Web de Datos: Como crear aplicaciones usando Linked Open Data
Alvaro Graves
 
Improving decision-making based on government data and visualizations
Improving decision-making based on government data and visualizationsImproving decision-making based on government data and visualizations
Improving decision-making based on government data and visualizations
Alvaro Graves
 
Creating web applications with LODSPeaKr
Creating web applications with LODSPeaKrCreating web applications with LODSPeaKr
Creating web applications with LODSPeaKr
Alvaro Graves
 
Publicando RDF y Linked Data con LODSPeaKr
Publicando RDF  y Linked Data con LODSPeaKrPublicando RDF  y Linked Data con LODSPeaKr
Publicando RDF y Linked Data con LODSPeaKr
Alvaro Graves
 
Open Data y participación ciudadana
Open Data y participación ciudadanaOpen Data y participación ciudadana
Open Data y participación ciudadana
Alvaro Graves
 
Web semántica y linked data la web como bd
Web semántica y linked data  la web como bdWeb semántica y linked data  la web como bd
Web semántica y linked data la web como bd
Alvaro Graves
 
LODSPeaKr - Use cases Lighting Talk
LODSPeaKr - Use cases Lighting TalkLODSPeaKr - Use cases Lighting Talk
LODSPeaKr - Use cases Lighting Talk
Alvaro Graves
 
Publishing Linked Open Data in 15 minutes
Publishing Linked Open Data in 15 minutesPublishing Linked Open Data in 15 minutes
Publishing Linked Open Data in 15 minutes
Alvaro Graves
 
TWC LOGD: A Portal for Linking Government Data
TWC LOGD: A Portal for Linking Government DataTWC LOGD: A Portal for Linking Government Data
TWC LOGD: A Portal for Linking Government Data
Alvaro Graves
 
POMELo: A PML Online Editor
POMELo: A PML Online EditorPOMELo: A PML Online Editor
POMELo: A PML Online Editor
Alvaro Graves
 
Democratizing Open Data
Democratizing Open DataDemocratizing Open Data
Democratizing Open Data
Alvaro Graves
 
Explotando la Web de Datos: Como crear aplicaciones usando Linked Open Data
Explotando la Web de Datos: Como crear aplicaciones usando Linked Open DataExplotando la Web de Datos: Como crear aplicaciones usando Linked Open Data
Explotando la Web de Datos: Como crear aplicaciones usando Linked Open Data
Alvaro Graves
 
Improving decision-making based on government data and visualizations
Improving decision-making based on government data and visualizationsImproving decision-making based on government data and visualizations
Improving decision-making based on government data and visualizations
Alvaro Graves
 
Creating web applications with LODSPeaKr
Creating web applications with LODSPeaKrCreating web applications with LODSPeaKr
Creating web applications with LODSPeaKr
Alvaro Graves
 
Publicando RDF y Linked Data con LODSPeaKr
Publicando RDF  y Linked Data con LODSPeaKrPublicando RDF  y Linked Data con LODSPeaKr
Publicando RDF y Linked Data con LODSPeaKr
Alvaro Graves
 
Open Data y participación ciudadana
Open Data y participación ciudadanaOpen Data y participación ciudadana
Open Data y participación ciudadana
Alvaro Graves
 
Web semántica y linked data la web como bd
Web semántica y linked data  la web como bdWeb semántica y linked data  la web como bd
Web semántica y linked data la web como bd
Alvaro Graves
 
LODSPeaKr - Use cases Lighting Talk
LODSPeaKr - Use cases Lighting TalkLODSPeaKr - Use cases Lighting Talk
LODSPeaKr - Use cases Lighting Talk
Alvaro Graves
 
Publishing Linked Open Data in 15 minutes
Publishing Linked Open Data in 15 minutesPublishing Linked Open Data in 15 minutes
Publishing Linked Open Data in 15 minutes
Alvaro Graves
 
TWC LOGD: A Portal for Linking Government Data
TWC LOGD: A Portal for Linking Government DataTWC LOGD: A Portal for Linking Government Data
TWC LOGD: A Portal for Linking Government Data
Alvaro Graves
 
POMELo: A PML Online Editor
POMELo: A PML Online EditorPOMELo: A PML Online Editor
POMELo: A PML Online Editor
Alvaro Graves
 

Recently uploaded (20)

Breaking it Down: Microservices Architecture for PHP Developers
Breaking it Down: Microservices Architecture for PHP DevelopersBreaking it Down: Microservices Architecture for PHP Developers
Breaking it Down: Microservices Architecture for PHP Developers
pmeth1
 
Pushing the Limits: CloudStack at 25K Hosts
Pushing the Limits: CloudStack at 25K HostsPushing the Limits: CloudStack at 25K Hosts
Pushing the Limits: CloudStack at 25K Hosts
ShapeBlue
 
AI and Gender: Decoding the Sociological Impact
AI and Gender: Decoding the Sociological ImpactAI and Gender: Decoding the Sociological Impact
AI and Gender: Decoding the Sociological Impact
SaikatBasu37
 
Interactive SQL: SQL, Features of SQL, DDL & DML
Interactive SQL: SQL, Features of SQL,  DDL & DMLInteractive SQL: SQL, Features of SQL,  DDL & DML
Interactive SQL: SQL, Features of SQL, DDL & DML
IsakkiDeviP
 
SQL Database Design For Developers at PhpTek 2025.pptx
SQL Database Design For Developers at PhpTek 2025.pptxSQL Database Design For Developers at PhpTek 2025.pptx
SQL Database Design For Developers at PhpTek 2025.pptx
Scott Keck-Warren
 
Storage Setup for LINSTOR/DRBD/CloudStack
Storage Setup for LINSTOR/DRBD/CloudStackStorage Setup for LINSTOR/DRBD/CloudStack
Storage Setup for LINSTOR/DRBD/CloudStack
ShapeBlue
 
Multi-Agent AI Systems: Architectures & Communication (MCP and A2A)
Multi-Agent AI Systems: Architectures & Communication (MCP and A2A)Multi-Agent AI Systems: Architectures & Communication (MCP and A2A)
Multi-Agent AI Systems: Architectures & Communication (MCP and A2A)
HusseinMalikMammadli
 
AI Unboxed - How to Approach AI for Maximum Return
AI Unboxed - How to Approach AI for Maximum ReturnAI Unboxed - How to Approach AI for Maximum Return
AI Unboxed - How to Approach AI for Maximum Return
Merelda
 
"AI in the browser: predicting user actions in real time with TensorflowJS", ...
"AI in the browser: predicting user actions in real time with TensorflowJS", ..."AI in the browser: predicting user actions in real time with TensorflowJS", ...
"AI in the browser: predicting user actions in real time with TensorflowJS", ...
Fwdays
 
Building Connected Agents: An Overview of Google's ADK and A2A Protocol
Building Connected Agents:  An Overview of Google's ADK and A2A ProtocolBuilding Connected Agents:  An Overview of Google's ADK and A2A Protocol
Building Connected Agents: An Overview of Google's ADK and A2A Protocol
Suresh Peiris
 
GraphSummit Singapore Master Deck - May 20, 2025
GraphSummit Singapore Master Deck - May 20, 2025GraphSummit Singapore Master Deck - May 20, 2025
GraphSummit Singapore Master Deck - May 20, 2025
Neo4j
 
John Carmack’s Slides From His Upper Bound 2025 Talk
John Carmack’s Slides From His Upper Bound 2025 TalkJohn Carmack’s Slides From His Upper Bound 2025 Talk
John Carmack’s Slides From His Upper Bound 2025 Talk
Razin Mustafiz
 
How to Integrate FME with Databricks (and Why You’ll Want To)
How to Integrate FME with Databricks (and Why You’ll Want To)How to Integrate FME with Databricks (and Why You’ll Want To)
How to Integrate FME with Databricks (and Why You’ll Want To)
Safe Software
 
MCP Dev Summit - Pragmatic Scaling of Enterprise GenAI with MCP
MCP Dev Summit - Pragmatic Scaling of Enterprise GenAI with MCPMCP Dev Summit - Pragmatic Scaling of Enterprise GenAI with MCP
MCP Dev Summit - Pragmatic Scaling of Enterprise GenAI with MCP
Sambhav Kothari
 
Apache CloudStack 101 - Introduction, What’s New and What’s Coming
Apache CloudStack 101 - Introduction, What’s New and What’s ComingApache CloudStack 101 - Introduction, What’s New and What’s Coming
Apache CloudStack 101 - Introduction, What’s New and What’s Coming
ShapeBlue
 
Partner Tableau Next Product First Call Deck.pdf
Partner Tableau Next Product First Call Deck.pdfPartner Tableau Next Product First Call Deck.pdf
Partner Tableau Next Product First Call Deck.pdf
ssuser3d62c6
 
The fundamental misunderstanding in Team Topologies
The fundamental misunderstanding in Team TopologiesThe fundamental misunderstanding in Team Topologies
The fundamental misunderstanding in Team Topologies
Patricia Aas
 
Optimize IBM i with Consulting Services Help
Optimize IBM i with Consulting Services HelpOptimize IBM i with Consulting Services Help
Optimize IBM i with Consulting Services Help
Alice Gray
 
Building Agents with LangGraph & Gemini
Building Agents with LangGraph &  GeminiBuilding Agents with LangGraph &  Gemini
Building Agents with LangGraph & Gemini
HusseinMalikMammadli
 
TAFs on WebDriver API - By - Pallavi Sharma.pdf
TAFs on WebDriver API - By - Pallavi Sharma.pdfTAFs on WebDriver API - By - Pallavi Sharma.pdf
TAFs on WebDriver API - By - Pallavi Sharma.pdf
Pallavi Sharma
 
Breaking it Down: Microservices Architecture for PHP Developers
Breaking it Down: Microservices Architecture for PHP DevelopersBreaking it Down: Microservices Architecture for PHP Developers
Breaking it Down: Microservices Architecture for PHP Developers
pmeth1
 
Pushing the Limits: CloudStack at 25K Hosts
Pushing the Limits: CloudStack at 25K HostsPushing the Limits: CloudStack at 25K Hosts
Pushing the Limits: CloudStack at 25K Hosts
ShapeBlue
 
AI and Gender: Decoding the Sociological Impact
AI and Gender: Decoding the Sociological ImpactAI and Gender: Decoding the Sociological Impact
AI and Gender: Decoding the Sociological Impact
SaikatBasu37
 
Interactive SQL: SQL, Features of SQL, DDL & DML
Interactive SQL: SQL, Features of SQL,  DDL & DMLInteractive SQL: SQL, Features of SQL,  DDL & DML
Interactive SQL: SQL, Features of SQL, DDL & DML
IsakkiDeviP
 
SQL Database Design For Developers at PhpTek 2025.pptx
SQL Database Design For Developers at PhpTek 2025.pptxSQL Database Design For Developers at PhpTek 2025.pptx
SQL Database Design For Developers at PhpTek 2025.pptx
Scott Keck-Warren
 
Storage Setup for LINSTOR/DRBD/CloudStack
Storage Setup for LINSTOR/DRBD/CloudStackStorage Setup for LINSTOR/DRBD/CloudStack
Storage Setup for LINSTOR/DRBD/CloudStack
ShapeBlue
 
Multi-Agent AI Systems: Architectures & Communication (MCP and A2A)
Multi-Agent AI Systems: Architectures & Communication (MCP and A2A)Multi-Agent AI Systems: Architectures & Communication (MCP and A2A)
Multi-Agent AI Systems: Architectures & Communication (MCP and A2A)
HusseinMalikMammadli
 
AI Unboxed - How to Approach AI for Maximum Return
AI Unboxed - How to Approach AI for Maximum ReturnAI Unboxed - How to Approach AI for Maximum Return
AI Unboxed - How to Approach AI for Maximum Return
Merelda
 
"AI in the browser: predicting user actions in real time with TensorflowJS", ...
"AI in the browser: predicting user actions in real time with TensorflowJS", ..."AI in the browser: predicting user actions in real time with TensorflowJS", ...
"AI in the browser: predicting user actions in real time with TensorflowJS", ...
Fwdays
 
Building Connected Agents: An Overview of Google's ADK and A2A Protocol
Building Connected Agents:  An Overview of Google's ADK and A2A ProtocolBuilding Connected Agents:  An Overview of Google's ADK and A2A Protocol
Building Connected Agents: An Overview of Google's ADK and A2A Protocol
Suresh Peiris
 
GraphSummit Singapore Master Deck - May 20, 2025
GraphSummit Singapore Master Deck - May 20, 2025GraphSummit Singapore Master Deck - May 20, 2025
GraphSummit Singapore Master Deck - May 20, 2025
Neo4j
 
John Carmack’s Slides From His Upper Bound 2025 Talk
John Carmack’s Slides From His Upper Bound 2025 TalkJohn Carmack’s Slides From His Upper Bound 2025 Talk
John Carmack’s Slides From His Upper Bound 2025 Talk
Razin Mustafiz
 
How to Integrate FME with Databricks (and Why You’ll Want To)
How to Integrate FME with Databricks (and Why You’ll Want To)How to Integrate FME with Databricks (and Why You’ll Want To)
How to Integrate FME with Databricks (and Why You’ll Want To)
Safe Software
 
MCP Dev Summit - Pragmatic Scaling of Enterprise GenAI with MCP
MCP Dev Summit - Pragmatic Scaling of Enterprise GenAI with MCPMCP Dev Summit - Pragmatic Scaling of Enterprise GenAI with MCP
MCP Dev Summit - Pragmatic Scaling of Enterprise GenAI with MCP
Sambhav Kothari
 
Apache CloudStack 101 - Introduction, What’s New and What’s Coming
Apache CloudStack 101 - Introduction, What’s New and What’s ComingApache CloudStack 101 - Introduction, What’s New and What’s Coming
Apache CloudStack 101 - Introduction, What’s New and What’s Coming
ShapeBlue
 
Partner Tableau Next Product First Call Deck.pdf
Partner Tableau Next Product First Call Deck.pdfPartner Tableau Next Product First Call Deck.pdf
Partner Tableau Next Product First Call Deck.pdf
ssuser3d62c6
 
The fundamental misunderstanding in Team Topologies
The fundamental misunderstanding in Team TopologiesThe fundamental misunderstanding in Team Topologies
The fundamental misunderstanding in Team Topologies
Patricia Aas
 
Optimize IBM i with Consulting Services Help
Optimize IBM i with Consulting Services HelpOptimize IBM i with Consulting Services Help
Optimize IBM i with Consulting Services Help
Alice Gray
 
Building Agents with LangGraph & Gemini
Building Agents with LangGraph &  GeminiBuilding Agents with LangGraph &  Gemini
Building Agents with LangGraph & Gemini
HusseinMalikMammadli
 
TAFs on WebDriver API - By - Pallavi Sharma.pdf
TAFs on WebDriver API - By - Pallavi Sharma.pdfTAFs on WebDriver API - By - Pallavi Sharma.pdf
TAFs on WebDriver API - By - Pallavi Sharma.pdf
Pallavi Sharma
 

Visualizations using Visualbox

  • 1. VISUALIZATIONS WITH SPARQL AND VISUALBOX Alvaro Graves @alvarograves [email protected]
  • 2. MOTIVATION Linked Data brings tons of multidimensional data that is easy(*) to query However, having to make use of all that data we still need to being able to process it (as humans) One good way to make sense of this data is by using visualizations (*) Once you learn SPARQL
  • 3. EXAMPLE versus Images: Few, Stephen (2010): Data Visualization for Human Perception. In: Soegaard, Mads and Dam, Rikke Friis (eds.). "Encyclopedia of Human-Computer Interaction". Aarhus, Denmark: The Interaction Design Foundation. Available online at http://www.interaction-design.org/encyclopedia/data_visualization_for_human_perception.html
  • 4. VISUALBOX Based on LODSPeaKr Make use of new and already existing visualization filters Creating of visualization via new GUI Principle: Good data representation leads to good/easy data manipulation Corolary: Effort should be focused on obtaining the right data
  • 6. MODELS (SPARQL QUERY) Using the SELECT query form will return a table, similar to SQL. main.query PREFIX foaf: <http://xmlns.com/foaf/0.1/> SELECT ?person1 ?person2 WHERE{ ?person1 foaf:knows ?person2 . } person1 person2 http://example.org/john http://example.org/paul http://example.org/john http://example.org/ringo http://example.org/george http://example.org/paul
  • 7. VIEWS (TEMPLATES) We can decide how to operate with the data. html.template <ul> {{for row in models.main}} <li>{{row.person1.value}} knows {{row.person2.value}}</li> {{endfor}} </ul> output http://example.org/john knows http://example.org/paul http://example.org/john knows http://example.org/ringo http://example.org/george knows http://example.org/paul
  • 8. FILTERS It is possible to apply filters to the data. Template {{for row in models.main}} {{row.person1.value|upper}} {{endfor}} Output HTTP://EXAMPLE.ORG/JOHN HTTP://EXAMPLE.ORG/JOHN HTTP://EXAMPLE.ORG/GEORGE
  • 9. VISUALIZATION FILTERS It is possible to apply visualization filters directly to all the results. These filters will generate the necessary code to create a visualization Model (main.query) PREFIX cat: <http://dbpedia.org/resource/Category:> SELECT ?countryLabel (COUNT(?nobel) as ?total) WHERE { ?nobel dcterms:subject cat:Nobel_laureates_in_Physics; a foaf:Person; dbp:placeOfBirth ?country . ?country a schema:Country ; rdfs:label ?countryLabel FILTER(LANG(?countryLabel) = "en") }GROUP BY ?country ?countryLabel ORDER BY DESC(?total) LIMIT 100
  • 10. countryLabel total United States 23 Germany 14 England 9 Japan 6 Austria-Hungary 5 France 5 Netherlands 4 German Empire 3 Soviet Union 3 United Kingdom 3 Italy 3
  • 11. View (html.template) <body> <h2>Total of Nobel laureates in Physics by country</h2> {{models.main|GoogleVizPieChart:"countryLabel,total"}} </body>
  • 12. TABULAR DATA Easiest case: consider table-based visualizations. View (html.template) {{models.main|GoogleVizColumnChart:"countryLabel,total"}}
  • 15. MAPS Represent data as latitude, longitude and label SELECT DISTINCT ?city SAMPLE(?lat) AS ?latitude SAMPLE(?long) AS ?longitude ?area WHERE{ ?city a sch:City ; <http://dbpedia.org/ontology/country> <http://dbpedia.org/resource/United_States> ; geo:lat ?lat ; geo:long ?long; dbp:areaTotalKm ?area . }GROUP BY ?city ?area ORDER BY DESC(?area) LIMIT 10
  • 16. latitude longitude area 45.4983 -91.7389 25.0 30.3167 -81.6667 2292 45.9989 -112.53 1868
  • 18. PARALLEL COORDINATES Query SELECT ?carLabel ?wheelbase ?carWidth ?carLength ?transmission WHERE { ?car dcterms:subject <http://dbpedia.org/resource/Category:Lamborghini_vehicles>; <http://dbpedia.org/ontology/Automobile/wheelbase> ?wheelbase; <http://dbpedia.org/ontology/MeanOfTransportation/height> ?carWidth; <http://dbpedia.org/ontology/MeanOfTransportation/length> ?carLength; <http://dbpedia.org/property/transmission> ?transmission; rdfs:label ?carLabel. FILTER(LANG(?carLabel) = "en") }
  • 19. PARALLEL COORDINATES carLabel wheelbase carWidth carLength transmission Lamborghini Aventador 2700.0 1136.0 4780.0 7 Lamborghini Reventón 2665.0 1135.0 4700.0 6 Lamborghini 400GT 2550.0 1257.0 4470.0 5 Template {{models.main|D3ParallelCoordinates:"carLabel,wheelbase,carWidth,carLength,transmission"}}
  • 21. GRAPHS Question: How to express a graph in a table? Answer: Table child → parent Model (main.query) SELECT ?person1 ?person2 WHERE{ ?person1 foaf:knows ?person2 . } person1 person2 Elizabeth Engstrom Ray Bradbury Neil Gaiman Robert A. Heinlein Neil Gaiman Ray Bradbury
  • 22. View (html.template) {{models.main|D3ForceGraph:"person1,person2"}}
  • 23. TREE STRUCTURES Problem: How do we retrieve a tree as a table? Solution (so far): Table child,parent with one row with no parent (root) child parent area Averill Park, New York Rensselaer County, New York 8.02896e+06 Sand Lake, New York Rensselaer County, New York 9.36e+07 Schaghticoke (town), New York Rensselaer County, New York 1.3442e+08 Poestenkill (town), New York Rensselaer County, New York 8.44336e+07 Schaghticoke (village), New York Rensselaer County, New York 2.33099e+06 Rensselaer County, New York
  • 24. TREE STRUCTURES Query PREFIX d: <http://dbpedia.org/ontology/> SELECT max(?regionLabel) as ?child max(?superregionLabel) as ?parent (max(?totalArea) as ?area) WHERE{ { ?region d:isPartOf <http://dbpedia.org/resource/Rensselaer_County,_New_York>; d:areaTotal ?totalArea ; rdfs:label ?regionLabel; d:isPartOf ?superregion . ?superregion rdfs:label ?superregionLabel. FILTER(?superregion = <http://dbpedia.org/resource/Rensselaer_County,_New_York>) FILTER(lang(?superregionLabel) = "en") }UNION{ ?region rdfs:label ?regionLabel . FILTER(?region = <http://dbpedia.org/resource/Rensselaer_County,_New_York>) } FILTER(lang(?regionLabel) = "en") }GROUP BY ?regionLabel ?superregionLabel Template {{models.main|D3CirclePacking:"child,parent,area"}}
  • 26. TREE STRUCTURES (2) Query (neruda.query) PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> PREFIX dbp: <http://dbpedia.org/ontology/> PREFIX d: <http://dbpedia.org/resource/> SELECT DISTINCT ?child ?parent WHERE{ { ?childNode dbp:influencedBy ?mid ; rdfs:label ?child . ?mid dbp:influencedBy ?parentNode; rdfs:label ?parent . FILTER(LANG(?parent) = "en" && ?parentNode = d:Pablo_Neruda) }UNION{ ?childNode dbp:influencedBy d:Pablo_Neruda; dbp:influencedBy ?parentNode; rdfs:label ?child . ?parentNode rdfs:label ?parent . FILTER(LANG(?parent) = "en" && ?parentNode = d:Pablo_Neruda) }UNION{ d:Pablo_Neruda rdfs:label ?child } FILTER(LANG(?child) = "en") }
  • 27. child parent Pablo Neruda Dane Zajc Pablo Neruda Gary Soto Pablo Neruda James Tate (writer) Pablo Neruda Richard Aitson Pablo Neruda Erin Siegal Pablo Neruda Jože Snoj Dane Zajc Rudi Šeligo Dane Zajc Veno Taufer Dane Zajc Rigoberto González Gary Soto Thomas Lux James Tate (writer) html.template {{models.main|D3Dendrogram:"child,parent"}}
  • 29. NOW YOU CREATE YOUR OWN VISUALIZATION Use data that is of interest for you Describe to tell a story or support a statement Give me feedback on how does visualbox works for you