[R] 3D graph - automated way

Rado Bonk rado.bonk at jrc.it
Wed May 31 18:37:37 CEST 2006


Dear R-users,

On behalf of my colleague I would like to ask you for a help:

I have to produce a 3D graphs from several two-column files. Each file 
has around 20-30k of lines.

EXAMPLE OF TWO_COLUMNS_FILE - col_names:(EPS, UPS)

8	725
8	825
3	1025
10	9950
9	10000
8	10350
8	10500
10	6950
3	1000
7	11125
5	11200
5	11425
10	7050
2	950
5	11775
10	7100
4	400
3	900
3	400
6	12325
9	7250
4	625
4	575
3	550
3	325


Histograms for EPS bins (2,5,10)[=>X-axis]  which are nested in 
histogram of UPS bins (500,1000,5000)[=>Y-axis].
The Z-axis values are the number of occurences of the binned pairs.
Need to process large amount of these files (no fixed number of rows).

Endproduct 3D histograms for each file (see example here: 
ftp://ftplmu.jrc.it/outgoing/rado/histo.JPG)


I proceeded like this, but maybe there are already utilities that can 
handle something like that:

Sort for UPS:
3	325
4	400
3	400
3	550
4	575
4	625
8	725
8	825
3	900
2	950
3	1000
3	1025
10	6950
10	7050
10	7100
9	7250
10	9950
9	10000
8	10350
8	10500
7	11125
5	11200
5	11425
5	11775
6	12325

Histogram:
1st bin UPS(0<y<500) =
3	325
4	400
3	400
= 3 in EPS bin(2<x<5) ; 0 in all other EPS bins => Z values

2nd bin UPS(500<y<1000) =
3	550
4	575
4	625
8	725
8	825
3	900
2	950
= 1 in EPS bin(0<x<2) ; 4 in EPS bin(2<x<5) ; 2 in EPS bin(5<x<10)  => Z 
values




Thanks in advance,


Rado (for Jens)





-- 
Radoslav Bonk Ph.D
European Commission - DG  Joint Research Centre (JRC)
Institute of Environment and Sustainability (IES)
LM Unit - Natural Hazards
Via E. Fermi, TP 261, 210 20 Ispra (VA), ITALY
tel: 0039 0332 78 6013
fax: 0039 0332 78 6653
http://natural-hazards.jrc.it/floods



More information about the R-help mailing list