File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -315,15 +315,17 @@ sub transform {
315315 my ($this ,$point ,$data ,$inds ) = @_ ;
316316 PDL::barf " no \$ inds given" if !defined $inds ;
317317 barf " Wrong number of arguments to transform $this \n " if @$inds != 3;
318+ my ($longrange , $latrange ) = map $this -> {Scale }[$_ ][1] - $this -> {Scale }[$_ ][0], 0,1;
319+ my $pressure_max = $this -> {Scale }[2][1];
318320 $point -> slice(" (0)" ) +=
319321 0.5+($data -> slice(" ($inds ->[0])" )-$this -> {Center }[0]) /
320- ( $this -> { Scale }[0][1] - $this -> { Scale }[0][0])
322+ $longrange
321323 *cos ($data -> slice(" ($inds ->[1])" )*DEG2RAD);
322324 $point -> slice(" (1)" ) +=
323325 0.5+($data -> slice(" ($inds ->[1])" )-$this -> {Center }[1]) /
324- ( $this -> { Scale }[1][1] - $this -> { Scale }[1][0]) ;
326+ $latrange ;
325327 $point -> slice(" (2)" ) .=
326- log ($data -> slice(" ($inds ->[2])" )/1012.5)/log ($this -> { Scale }[2][1] /1012.5);
328+ log ($data -> slice(" ($inds ->[2])" )/1012.5)/log ($pressure_max /1012.5);
327329 $point ;
328330}
329331
You can’t perform that action at this time.
0 commit comments