Hi,
**Important Disclaimer**: Please consider this an alpha draft.
Information depicted is not yet verified or the final one.
Here is the last version of this:
Still we need to explain color conventions (nothing difficult), but the
matrix sunburst plus rotated labels (+ color conventions) is a concise
way for having a quick overview of what's happening on information of
considerable size. The interactive matrix sunburst lets the user to put
the mouse over a particular part of the grid and obtain some details.
The idea was to visualize gaps or absences of information (with the
color white), and who and what is being publishing (or not) in the case
of some drugs and medicines.
Despite of being public information, is sensible one, so we need to
triple check everything before releasing the data (specially that labels
correspond the the labeled columns! and that all is consistent). My
friend, who is the domain expert on drugs and medicine is now taking her
end of year vacations, but she is willing to put data and visualizations
released as open research. Code has been published already on
Smalltalkhub under the DataViz project, but we plan to release code,
data, and maybe some small companion grafoscopio notebook integrating
both, to make complete sense of the package.
As soon as I have the details worked out, I plan to blog about how agile
visualization and Roassal can help in building specific domain
visualizations, used in this case for understanding health information
publishing issues.
This is a small preview of how interactive documentation, data
visualization and open science & research have a fertile landscape in
the Pharo ecosystem.
I will let you know how this advances and, as always, thanks for all the
help.
Offray
On 24/12/15 17:13, Alexandre Bergel wrote:
Excellent
Alex
Le 24 déc. 2015 à 14:08, Offray Vladimir Luna Cárdenas
<offray.luna(a)mutabit.com <mailto:offray.luna@mutabit.com>> a écrit :
Thanks Milton!
It works like a charm :-)
<dgiafiic.>
Cheers,
Offray
On 24/12/15 10:01, milton mamani wrote:
Hi Offray
Can you try the next piece of code.
.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=
| view center data diameter angle gap |
diameter := 100.
gap := 5.
view := RTView new.
data := #('lion-o' 'tigro' 'chitara' 'munra'
'ozimandias' 'Dr
Manhatan').
center := RTEllipse new
size: diameter;
color: Color white;
borderColor: Color veryLightGray.
view add: center element.
1 to: data size do: [ :index | | label |
angle := (index * 360/ data size) degreesToRadians.
label := (RTRotatedLabel new
text: (data at: index);
height: 5) element.
label translateBy: (Point r: label trachelShape
notRotatedWidth/2+(diameter/2)+gap theta: angle).
view add: label.
angle := angle radiansToDegrees.
angle := angle + ((angle between: 90 and: 270) ifTrue: [ 180 ]
ifFalse: [ 0 ]).
label trachelShape angleInDegree: angle.
].
view
.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=.=
Cheers,
Milton
2015-12-23 20:36 GMT-04:00 Offray Vladimir Luna Cárdenas
<offray.luna(a)mutabit.com>om>:
Hi,
I'm trying to understand the code behind the figure here to
rotate labels:
<mime-attachment.png>
So, I made a minimal example to start with, here (code is at
http://ws.stfx.eu/N6ZG4BAIBO00 )
<mime-attachment.png>
Now I would like to rotate the text to made it look like the
first image. I presume that the code that made this possible for
the first case is this one:
====================
RTBundleBuilder>>createLabelFor: e view: aView
| lbl |
lbl := label elementOn: e model.
self interaction setUpElement: lbl.
aView add: lbl.
e addCallback: (TRTranslationCallback new block: [
| angle |
angle := (e position - center ) theta.
lbl translateTo: e position+((lbl trachelShape
notRotatedWidth/2) * (angle cos @ angle sin)).
angle := angle radiansToDegrees.
angle := angle + ((angle between: 90 and: 270) ifTrue:
[ 180 ] ifFalse: [ 0 ]).
lbl trachelShape angleInDegree: angle ] ).
e translateTo: e position.
====================
but I can not quite understand the lines
lbl translateTo: e position+((lbl trachelShape
notRotatedWidth/2) * (angle cos @ angle sin)).
and
angle := angle + ((angle between: 90 and: 270) ifTrue: [ 180 ]
ifFalse: [ 0 ]).
Could some body explain me how to incorporate rotation to the
first basic example at
http://ws.stfx.eu/N6ZG4BAIBO00 (second
image of this mail).
Thanks,
Offray
_______________________________________________
Moose-dev mailing list
Moose-dev(a)list.inf.unibe.ch <mailto:Moose-dev@list.inf.unibe.ch>
https://www.list.inf.unibe.ch/listinfo/moose-dev
_______________________________________________
Moose-dev mailing list
Moose-dev(a)list.inf.unibe.ch
https://www.list.inf.unibe.ch/listinfo/moose-dev
_______________________________________________
Moose-dev mailing list
Moose-dev(a)list.inf.unibe.ch <mailto:Moose-dev@list.inf.unibe.ch>
https://www.list.inf.unibe.ch/listinfo/moose-dev
_______________________________________________
Moose-dev mailing list
Moose-dev(a)list.inf.unibe.ch
https://www.list.inf.unibe.ch/listinfo/moose-dev