(Note: the new programme PRX will also Alter and Sort post files...)
Most neutron probe sites consist of three tubes, and the readings are normally averaged and put in a single readings screen. However, some growers also need to save readings from individual tubes to see if there is a significant difference between them, as well as saving the averaged readings.
To solve this problem, it is suggested that Probe users should give each tube an individual FarmSite number (in the example below, Farm 1, Sites 1, 2 and 3). On the Probe software four sites are created - Sites 1, 2 and 3; and in addition a Site 5 that will be the 'average' of the three tubes.
Probe readings are taken in the field, entering an ID=101 for the first tube; ID=102
for the second, etc; ID=105 is not entered in the field. The readings are then
uploaded to the microcomputer, and the post file (POST.DAT
in the example below) is then posted normally. The readings will be in Sites 1, 2 and 3.
Now exit from the Probe software, and run the programme ALTER
, telling ALTER to use the information in the file ALTER.SET.
C:\PROBE> ALTER ALTER.SET
This will produce a new post file (POSTAVG.PST
in the example below).
Now restart the Probe software, and post the new post file (you will need to
change the name of the post file, to POSTAVG.PST in
this example). The averaged readings will now be in Site 5.
Some neutron probes have only 8 calibrations, and users with these probes should use the command...
ALTER ALTER.SET /8
ALTER reads a text file (ALTER.SET). Users must edit this file, using DOS EDIT, or any other word processor, to set the changes
that are required. The file ALTER.SET can have any
name - just type the required name when running ALTER.
C:\PROBE> ALTER ALTER.SET
Sometimes it may be necessary to sort the post file. Post Readings in the Probe
software will only average readings if they are together in the post file. If the tubes in
one site are not read consecutively they will not be together in the Post File. The DOS SORT programme can be used to sort a post File. However,
note that ID=0, used to enter date and time
information, will be sorted before all readings, even if they were entered in the middle
of the post file. The following command will sort the file POSTAVG.PST,
and put the result in the file AVGSRT.PST.
C:\PROBE\DATA> SORT < POSTAVG.PST > AVGSRT.PST
Format of >ALTER.SET
ALTER.SET starts with the names of the old and new post files, and then has
pairs of numbers - the old FarmSite number followed by the new FarmSite
number. A new FarmSite number of DELETE will not
copy the old readings to the new file. All other readings will be copied through.
| POST.DAT | name of original post file |
|---|---|
| POSTAVG.PST | name of output post file |
101, 105 |
FarmSite 101 will be changed to 105 |
102, 105 |
FarmSite 102 will be changed to 105 |
103, 105 |
FarmSite 103 will be changed to 105 |
117, delete |
FarmSite 117 will be deleted from the post file (already posted the first time, and do not need to average and re-post) |
There can be a maximum of 100 lines in the settings file. The settings file can have
any name - the required settings file is entered on the command line when ALTER is run.
ALTER2
The programme ALTER2 is more flexible than ALTER. It will optionally change the ID numbers, but will
also allow date and time information to be passed to the Probe software. The command
syntax is:
C:\PROBE> ALTER2 POST.DAT
Note that the file name is the name of the old post file, not the SET file.
ALTER2 will output a new file called POST.PST
- the same filename as the input file, but with the extension .PST.
This is the file name that will need entering when using PostReadings
in the Probe software.
The old and new FarmSite numbers are entered in the file ALTER2.SET
as pairs of numbers. Each line may also have a comment following a single quote.
101, 105 |
'FarmSite 101 will be changed to 105 |
102, 105 |
'FarmSite 102 will be changed to 105 |
103, 105 |
'FarmSite 103 will be changed to 105 |
If the ID number is not in the lookup table then the data is not output
(the opposite of ALTER). The SET file must be called ALTER2.SET.
If the date is entered in the Hydroprobe in the field as keydata item K2 and the time as K1,
then ALTER2 will convert these numbers and the
Probe software will automatically post the readings to the correct date and time. If ALTER2 is not used to alter the post file dates
and times they can only be entered with an ID=0
(the existing system). If ALTER2 is used,
dates and times can be entered with an ID=0 and
also when taking readings at an actual site.
Dates should be entered as ddmm (or mmdd - see /US
below)- for example 6th November should be entered as 6011
(or 1106). Times should be entered as hhmm - for example 4:32 pm should be entered as 1632.
The date needs to be entered only once each day (before the first reading of the day), and the time entered as frequently as necessary. For example, the time could be entered only at the first tube at each site. If the time or date is not entered, all following readings will be posted at the last time or date entered.
The following command line option switches are available.
/ALL |
copy all data lines - do not use the lookup table in ALTER2.SET |
/NDATE |
do not read the date information in K2
and K1 |
/ND |
copy data even if it does not appear in the lookup table. |
/US |
read the date information in K2 in
US format of mmdd |
/ICMS |
read date in K2 in mmddy format used by ICMS (the y
information is ignored). |
ALTER2 POST.DAT /ALL |
copy all readings (lookup table is not used at all), but do the date and time conversion. This could be used to routinely record date and time. |
ALTER2 POST.DAT /ALL /US |
copy all readings, but do date/time conversion with date in mmdd format |
ALTER2 POST.DAT /NDATE |
convert ID numbers using lookup table, but do not do date/time conversion |
ALTER2 POST.DAT /ICMS |
convert ID numbers, and do date/time conversion with date in ddmmy format |
The programme ALTER4 will repeat lines in
a file. It was designed for an irrigation control system that had several valves, each
with a different number, being controlled from one neutron probe monitoring site. The
allocation and sites reports have one line per probe site, but these lines needed
repeating with the site name changed to the name of the valve. For example, the line:
1 FIELD 1 1/4 332
is output as...
1 Valve 1 1/4 332
1 Valve 2 1/4 332
1 Valve 3 1/4 332
1 Valve 4 1/4 332
The command syntax is:
C:\PROBE>ALTER4 ALLOC.PRN ALLOUT.PRN /L:LOOKUP.DAT
Where ALLOC.PRN is the name of the text file
produced by the Probe software with reports, ALLOCOUT.PRN
is the name of the output file to be fed to the irrigation controller, and LOOKUP.DAT is the name of the file that contains a lookup
table relating the probe farm and site numbers to the valve numbers.
The file LOOKUP.DAT that was used to produce the
example above:
FIELD 1,Valve 1
FIELD 1,Valve 2
FIELD 1,Valve 3
FIELD 1,Valve 4
The pairs of items are separated by commas. Any line in the data file that is not in the lookup table will be output unchanged.
ALTER4 could also be used to alter a post file.
ALTER5 will re-format an allocation report so that it can be used as input
to an irrigation control system. It outputs a file of valve names, irrigation dates, and
amounts.
The programme will:
1. Calculate the total amount of water required by adding up all the amounts in the allocation report, even if they are divided over several time periods.
2. Multiply the amount of water recommended by the Probe software by a factor, and add a constant, to allow for irrigation delivery efficiencies, and to compensate for different areas covered by each valve (see 4 below).
OutputAmount = factor * Amount + constant
3. If the site is already below the refill point ('<fill' will appear as the predicted irrigation date), a default amount in the lookup file will be used. The irrigation date will be todays date, taken from the computers internal clock.
OutputAmount = factor * DefaultAmount + constant
The default amount in the lookup file should normally be set to (Full-Refill)*Area. The
screen of the Probe software calculates the equivalent depth of a user entered
volume of water, and the default amount in the lookup table should be the volume which
gives an equivalent depth of water equal to Full-Refill
(or the deficit) on the
screen.
4. Allow for an irrigation control system that has several valves, each with a different number, being controlled from one monitoring site. The allocation report has one line per probe site, and these lines will be repeated with the site name changed to the name of the valve.
The relationship between the Probe software site names and valve names, and the efficiency factors, must be entered in a separate lookup table - a standard DOS text file created with EDIT or any other word processor. Data for a site name in the input data file that is not in the lookup table will not be output
For example, the allocation report lines:
FIELD 1 1/4 - - - 300 32
FIELD 2 <fill - - - -
will be output (using the data in LOOKUP5.DAT below) as:
Valve 1, 1/4, 332
Valve 2, 1/4, 498
Valve 3, 1/4, 110
Valve 4, 1/4, 76
Valve 56, 28/3, 850
If the allocation report has been produced in Lotus format by the Probe software
(quotes around "text", dates as days-since-Jan 1 1900), the output from ALTER5 will have both the full date (including year) and the
time.
C:\PROBE>ALTER5 ALLOC.PRN ALLOUT.PRN /L:LOOKUP5.DAT
Where ALLOC.PRN is the name of the text file produced
by the Probe software with , ALLOCOUT.PRN is the name of the output file to be fed to the
irrigation controller, and LOOKUP5.DAT is the name of the
file that contains a lookup table relating the probe site names to the valve numbers, and
the efficiency factors.
The first line is a header line, and is ignored by ALTER5.
The rest of the file has five items per line, separated by commas. A comment following a
single quote ' will be ignored.
The file LOOKUP5.DAT that was used to produce
the example above:
SiteName,Valve,factor,constant,DefaultAmount
FIELD 1,Valve 1,1.0,0,500 "comment
FIELD 1,Valve 2,1.5,0,600
FIELD 1,Valve 3,0.3,10,100
FIELD 1,Valve 4,0.2,10,150 '2.3 Ha
Field 2,Valve 56,1.7,0,500
Site FIELD 1 is monitoring an area controlled by Valves 1,2 3 and 4. Valve 2 will have an amount equal to 1.5
* the amount in the allocation report. If FIELD 2
is below the refill value, the amount will be 500*1.7+0,
and the date set to today.
1. the command line item /L:LOOKUP.DAT must be
the last item on the line
2. the command line switch /Q will output quotes
around "text" items
3. the switch /ND will suppress display of the
status of the re-formatting
4. the switch /US will read and write dates in mm/dd
format (default is dd/mm)