note that ...all of people in this group are not guys.
i am girl.
____________________________

Nafiseh Saberi    ....   Iran.
____________________________
----- Original Message -----
From: "shirley" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 21, 2001 10:47 AM
Subject: please help out guys


> I've got a program running and extracting minimum values from the data
> base, but if there is no data available for the day on the data base, the
> value -999.9 is reflected. so how do I tell my program to skip the -999.9
> when reading the data and then select the minimum value out of the data
> base. pls check the program below:
>
>
> !/usr/bin/perl-w
> open(FH,"fort.4") || die " cannot open $list for reading : $!";
> open(OUT,">mm") || die "cannot create mm: $!";
> $tx_min =  9999;
> $tx_max =  -9999;
> $tn_min =  999;
> $tn_max =  -9999;
>
> while ($list = <FH> ){
> ($tn,$tx) = split (" ",$list);
> print " $tn\t $tx\n";
> if ($tn < $tn_min) { $tn_min = $tn }
> if ( $tn > $tn_max) { $tn_max = $tn }
> if ($tx < $tx_min) { $tx_min = $tx }
> if ( $tx > $tx_max) { $tx_max = $tx }
> $sum= $sum + $list ;
> $chan = abs($tn - $tn_min);
> }
> $mean = $sum/9;
> $change = abs($tn_min -$mean) *2 ;
> $pp = abs($tn_max -$tn_min) ;
>
> #$norm = $chan/$pp ;
> #print OUT " $norm\n";
> print OUT " $tn_min\n";
> #print OUT " $tn_min\t$tn_max\n";
>
> $name = "train";
> if (-e $name) {
>     print " the file is already there $name\n";
> } else {
>     print "perhaps you need make a new file $name\n";
> }
> close (train);
> close(OUT) || die "cant close mm: $!";
>
> "Your life is not a coincidence, its a reflection of You."
> ******************************************************************
> Movalo R.S
> Prediction Research
> South African Weather Service
> Pretoria, 0001
> Tel: 012 309 3807
> E-mail: [EMAIL PROTECTED]
> Call our Weather line at 082 162
> Visit our website at : www.weathersa.co.za
>
****************************************************************************
> **********
>
>
>
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to