Page 1 of 1

Statistics View

Posted: Mon Mar 11, 2013 1:16 pm
by adamhh
Dear Bruji

I adore the Statistics View and like to watch how certain values rise and fall as the collection expands. Visualisation of data is getting more and more interesting these days and can increasingly help us comprehend our information. However, the Statistics bar charts in the Pedias are very static and unidimensional at the moment. I suspect it is not easily done, but I was wondering if other ways of visualising data might be entertained such as Tag Clouds. This idea has been floating around the boards for a few years now - what's the current opinion?

Failing this, I wonder if some rows could be dynamically set. Eg. If any Year rows could be arranged chronologically as well as by amount. This would visualise how that variable peaks and troughs over time.

I'd also be interested in other's thoughts about data-visualisation and how it might be useful...

Re: Statistics View

Posted: Tue Mar 12, 2013 7:52 am
by Conor
The tag cloud idea has indeed been floating around for a while, but requires a lot of technical work to implement. So it's not being actively developed at the moment. There are two open versions that I could work from (Robert Pointon and the improved version by Jerry Krinock) but they are not close enough to what I would be looking for in the Pedias that it would require the same amount of work to incorporate. So hopefully as other features get done will have time to dedicate to enhancing the statistics as they are a definitely a fun part of the Pedias.

The chronological order has been requested before and I can see how it would make sense for the release year. I have updated the betas: DVDpedia, Bookpedia, CDpedia and Gamepedia with the required changes to allow chronological order for stats. In fact the next version will default to chronological order for the years.

Should you want to update some of the other stats or add both you can edit the statistics.xml file that is included inside the program resources. DVDpedia.app (Show Package Contents...)/Contents/Resources/statistics.xml.

To sort by label for any section append the following to the section in the XML:

Code: Select all

<key>sortByLabel</key>
<true/>
Price could be interesting shorted by price. You would find the price section and update it so the final bit would look like this:

Code: Select all

	<dict>
		<key>identifier</key>
		<string>price</string>
		<key>type</key>
		<integer>1</integer>
		<key>sortByLabel</key>
		<true/>
	</dict>
If you wanted to have both chronological and count order for release year you would duplicate the section of release year and change the "title" bit so the program does not see it as a duplicate. E.g.:

Code: Select all

	<dict>
		<key>identifier</key>
		<string>theatrical</string>
		<key>title</key>
		<string>Theatrical Release Years (Chronological)</string>
		<key>type</key>
		<integer>1</integer>
        <key>sortByLabel</key>
		<true/>
	</dict>
    <dict>
		<key>identifier</key>
		<string>theatrical</string>
		<key>title</key>
		<string>Theatrical Release Years</string>
		<key>type</key>
		<integer>1</integer>
	</dict>
If you change the statistics.xml file be sure to copy it over into your data folder so that program updates will not overwrite your changes. The new version will look for the local file by default first. The data folder is in ~/Library/Application Support/DVDpedia/statistics.xml.

Of course this means that should we ever add any new statistics you would need to update that file from the shipping version. But having your own statistics can be very useful especially for the custom fields.

The new setting works on the other labels should you want to sort author alphabetically or directors. This article has info about changing the appearance.

Re: Statistics View

Posted: Tue Mar 12, 2013 5:17 pm
by FineWine
Conor wrote:If you change the statistics.xml file be sure to copy it over into your data folder so that program updates will not overwrite your changes. The new version will look for the local file by default first. The data folder is in ~/Library/Application Support/DVDpedia/statistics.xml.

This article has info about changing the appearance.
Conor is there a way for you to make the program look for the statistics.html file also as a local file first as well? I like my pretty colours. :D

Re: Statistics View

Posted: Wed Mar 13, 2013 9:58 am
by Conor
Updated DVDpedia beta to find statistics.html in the data folder as well. Because of the images (stars) it still loads from inside the program, but the CSS will be read from the data folder. I.e. if using images they still need to be in images folder in "InfoTemplates" of the program and not locally.

Also fixed a bug with the stats "options" showing you the options for the built in version instead of the customization in statistics.xml in the data folder.

Re: Statistics View

Posted: Wed Mar 13, 2013 5:13 pm
by FineWine
Thank you Conor - it was a bit of a pain to keep updating that file within Package Contents after each update. I will wait for the Bookpedia and the others for their update.

Cheers

Re: Statistics View

Posted: Sun Mar 17, 2013 5:58 am
by Conor
Sorry it took me so long, I had to restructure the whole loading code to be flexible. Drop a copy of your files in the data folder and with the next update you won't even notice that you updated as it should pick it up automatically.

Re: Statistics View

Posted: Fri Jul 13, 2018 6:01 am
by genji2000
Hi Conor

What would I add to statistics.xml to sort Release Years in descending order?

Code: Select all

<dict>
		<key>identifier</key>
		<string>releaseDate</string>
		<key>title</key>
		<string>Release Years</string>
		<key>type</key>
		<integer>1</integer>
        	<key>sortByLabel</key>
		<true/>
	</dict>
Thanks.

Re: Statistics View

Posted: Sat Jul 14, 2018 3:43 am
by Conor
Not something I had taken into account, download beta 102 and then you can add:

Code: Select all

<key>descending</key>
<true/>

Re: Statistics View

Posted: Sun Jul 15, 2018 12:45 am
by genji2000
Sorry, Conor, I should've mentioned it's for Gamepedia, which I think is still on Beta 98.

Re: Statistics View

Posted: Mon Jul 16, 2018 2:51 am
by Conor
Sorry, Gamepedia Beta also updated.

Re: Statistics View

Posted: Mon Jul 16, 2018 5:22 am
by genji2000
Brilliant. Thanks, Conor.