<p><div><div><div><div data-width="100" data-show-faces="false" data-send="true" data-layout="button_count" data-height="21" data-href="http://www.r-bloggers.com/amazon-x-ray-data-provides-insight-into-movie-characters/"></div></div><div><a data-url="http://www.r-bloggers.com/amazon-x-ray-data-provides-insight-into-movie-characters/" data-counturl="http://www.r-bloggers.com/amazon-x-ray-data-provides-insight-into-movie-characters/" data-count="horizontal" data-text="Amazon X-ray data provides insight into movie characters" class="twitter-share-button" data-via="rbloggers" href="https://twitter.com/share"></a></div><div></div></div><div></div></div>
<div>
(This article was first published on <strong><a href="http://blog.revolutionanalytics.com/2016/06/amazon-x-ray-data-provides-insight-into-movie-characters.html"> Revolutions</a></strong>, and kindly contributed to <a rel="nofollow" href="http://www.r-bloggers.com/">R-bloggers)</a> </div>
<div>
<p>I'm a regular user of Amazon Video: as someone who spends a fair bit of time on planes, it's great to be able to download some of my favourite shows (hello, <em>Orphan Black</em> and <em>Vikings</em>) and catch up on episodes during the trip. Amazon Video has a useful feature, too: if you forget the name of a character, or if you see an an actor and wonder what other things they've been in, you can press pause and see a list of the actors appearing in the scene:</p>
<p><a target="_blank" href="http://revolution-computing.typepad.com/.a/6a010534b1db25970b01b8d1fc9ecd970c-pi"><img title="20160624_154926000_iOS" alt="20160624_154926000_iOS" src="http://revolution-computing.typepad.com/.a/6a010534b1db25970b01b8d1fc9ecd970c-800wi" border="0"></a></p>
<p>The feature is called <a target="_blank" href="http://www.imdb.com/x-ray/faq">X-Ray</a>, and I just learned from Curious Gnu that you <a target="_blank" href="http://www.curiousgnu.com/movie-character-screen-time">can download the data files that provide the X-Ray data</a>, as long as you have an Amazon Video subscription. The process isn't trivial (it involves using Developer Tools in Chrome to exploit a loophole in the streaming process), but at the end of the day you end up with a JSON file whcih you can easily read into R with the <a target="_blank" href="https://www.opencpu.org/posts/jsonlite-a-smarter-json-encoder/">jsonlite package</a> and then plot the data using any of R's visualization tools. For example, Curious Gnu created this visualization of the screentime of major Star Wars: The Force Awakens characters.</p>
<p><a target="_blank" href="http://www.curiousgnu.com/movie-character-screen-time"><img title="Tp_starwars" alt="Tp_starwars" src="http://revolution-computing.typepad.com/.a/6a010534b1db25970b01b8d1fca009970c-800wi" border="0"></a></p>
<p>Of course, another way of collecting data like this is to <a target="_blank" href="http://blog.revolutionanalytics.com/2016/01/analyzing-movie-connections-with-r.html">analyze the movie script</a>, but most scripts aren't readily available online (and even then, the format isn't exactly standardized). The advantage of using Amazon X-Ray JSON files is that the data is already structured, and are available for more movies and series … for as long as Amazon leaves the downloading loophole open.</p>
<p>For more details on how to download Amazon X-Ray data and more examples of movie data visualizations from Curious Gnu, follow the link below.</p>
<p>Curious Gnu: <a target="_blank" href="http://www.curiousgnu.com/movie-character-screen-time">Using Amazon's X-Ray to Visualize Characters' Screen Time</a> (<a target="_blank" href="https://twitter.com/ExpectAPatronum/status/746336742744199172">via</a> Verena Haunschmid)</p>
</div>
<p><div><div><div><div data-width="55" data-show-faces="false" data-send="true" data-layout="box_count" data-height="62" data-href="http://www.r-bloggers.com/amazon-x-ray-data-provides-insight-into-movie-characters/"></div></div><div><a data-url="http://www.r-bloggers.com/amazon-x-ray-data-provides-insight-into-movie-characters/" data-counturl="http://www.r-bloggers.com/amazon-x-ray-data-provides-insight-into-movie-characters/" data-count="vertical" data-text="Amazon X-ray data provides insight into movie characters" class="twitter-share-button" data-via="rbloggers" href="https://twitter.com/share"></a></div><div></div></div><div></div></div>
<div>
<div>To <strong>leave a comment</strong> for the author, please follow the link and comment on their blog: <strong><a href="http://blog.revolutionanalytics.com/2016/06/amazon-x-ray-data-provides-insight-into-movie-characters.html"> Revolutions</a></strong>.</div>
<hr>
<a rel="nofollow" href="http://www.r-bloggers.com/">R-bloggers.com</a> offers <strong><a rel="nofollow" href="http://feedburner.google.com/fb/a/mailverify?uri=RBloggers">daily e-mail updates</a></strong> about <a title="The R Project for Statistical Computing" rel="nofollow" href="http://www.r-project.org/">R</a> news and <a title="R tutorials" rel="nofollow" href="http://www.r-bloggers.com/?s=tutorial">tutorials</a> on topics such as: <a title="Data science" rel="nofollow" href="http://www.r-bloggers.com/?s=data%20science">Data science</a>, <a title="Big Data" rel="nofollow" href="http://www.r-bloggers.com/?s=Big%20Data">Big Data, <a title="R jobs" rel="nofollow" href="http://www.r-users.com/">R jobs</a>, visualization (<a title="ggplot and ggplot2 tutorials" rel="nofollow" href="http://www.r-bloggers.com/?s=ggplot2">ggplot2</a>, <a title="Boxplots using lattice and ggplot2 tutorials" rel="nofollow" href="http://www.r-bloggers.com/?s=boxplot">Boxplots</a>, <a title="Maps and gis" rel="nofollow" href="http://www.r-bloggers.com/?s=map">maps</a>, <a title="Animation in R" rel="nofollow" href="http://www.r-bloggers.com/?s=animation">animation</a>), programming (<a title="RStudio IDE for R" rel="nofollow" href="http://www.r-bloggers.com/?s=RStudio">RStudio</a>, <a title="Sweave and literate programming" rel="nofollow" href="http://www.r-bloggers.com/?s=sweave">Sweave</a>, <a title="LaTeX in R" rel="nofollow" href="http://www.r-bloggers.com/?s=LaTeX">LaTeX</a>, <a title="SQL and databases" rel="nofollow" href="http://www.r-bloggers.com/?s=SQL">SQL</a>, <a title="Eclipse IDE for R" rel="nofollow" href="http://www.r-bloggers.com/?s=eclipse">Eclipse</a>, <a title="git and github, Version Control System" rel="nofollow" href="http://www.r-bloggers.com/?s=git">git</a>, <a title="Large data in R using Hadoop" rel="nofollow" href="http://www.r-bloggers.com/?s=hadoop">hadoop</a>, <a title="Web Scraping of google, facebook, yahoo, twitter and more using R" rel="nofollow" href="http://www.r-bloggers.com/?s=Web+Scraping">Web Scraping</a>) statistics (<a title="Regressions and ANOVA analysis tutorials" rel="nofollow" href="http://www.r-bloggers.com/?s=regression">regression</a>, <a title="principal component analysis tutorial" rel="nofollow" href="http://www.r-bloggers.com/?s=PCA">PCA</a>, <a title="Time series" rel="nofollow" href="http://www.r-bloggers.com/?s=time+series">time series</a>, <a title="finance trading" rel="nofollow" href="http://www.r-bloggers.com/?s=trading">trading</a>) and more...
<img height="1" alt="" width="1" src="http://feeds.feedburner.com/~r/RBloggers/~4/vhKbHXsd7GM"></a></div>