very nice indeed.
but the HTML picture (link at the end) is not the same as the picture at
the beginning :-)
nicolas
On 30/03/2014 17:47, Alexandre Bergel wrote:
Hi!
So far 133 copies of Deep Into Pharo have been sold. I used Roassal2
to visualize countries
Here is a screenshot:
The data are embedded within the distribution of Roassal2. Just execute:
RTMetricMap new example06DeepIntoPharo
and you will get the same rendering.
The map builder has attracted some interest. Here is a small example
on how you can render you own data.
First of all, you need some data. Usually, you get data in a tabular
table. For example, I just stumbled on
http://www.gdbridge.org/gdb_index
I copy and paste the small columns on the right hand side of the web
page into a string in a workspace.
I then convert the third column as floats. I paint all countries in
white. I then paint countries from the table using the first column as
a name, and the third column as a color gradient
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
| b table |
b := RTMetricMap new.
table := RTTabTable new.
table input: 'Hong Kong, China10.631447
Singapore20.5889286
Netherlands30.515425
Switzerland40.5018929
United States50.4871152
Norway60.4851121
Denmark70.4665922
Sweden80.4567912
Finland90.4460537
Korea, Rep.100.4382369
Ireland110.4324097
Luxembourg120.4227912
Germany130.4190357
Belgium140.4022478
Canada150.3983661
Australia160.3982408
United Kingdom170.3930691
Japan180.3904902
Spain190.3876414
Kuwait200.3800776
France210.377015
Brunei Darussalam220.3627484
Austria230.3621858
Israel240.3585244
China250.3560882' usingDelimiters: String tab.
table convertColumn: 3 to: [ :t | Float readFrom: t ].
b allCountriesColor: Color white.
b countries: table values named: #first metric: #third.
b open
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Oh... almost forgot. You can export a visualization on the web. Here
is the generated HTML for the sells
https://dl.dropboxusercontent.com/u/31543901/online/DeepIntoPharoUntilMarch…
Cheers,
Alexandre
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel
http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev