| Environments | PYTHON :: EASI :: MODELER |
| Quick links | Description :: Parameters :: Parameter descriptions :: Details :: Example :: Related |
| Back to top |
| Back to top |
arrwrit(file, arrseg, format, tfile)
| Name | Type | Caption | Length | Value range |
|---|---|---|---|---|
| FILE * | str | File name | 1 - | |
| ARRSEG * | List[int] | Array segment | 1 - 1 | |
| FORMAT | str | Data format | 0 - 64 | |
| TFILE * | str | Text file name | 1 - 192 |
| Back to top |
FILE
Specifies the name of the PCIDSK image file that contains the array segment.
ARRSEG
Specifies the input array segment that will be written to the text file.
FORMAT
Optionally specifies the data format that will be used to write the array segment to the text file. For example:
"k * Fw.d ?"
Where:
TFILE
Specifies the name of the text file to which the array segment data is written.
You must run ARRWRIT before creating the text file. If a text file exists before ARRWRIT is run, it will be overwritten.
| Back to top |
ARRWRIT writes an array segment of data in a PCIDSK file to a text file. The format to use in writing the data can be specified with the FORMAT (Data Format) parameter.
| Back to top |
Write out the contents of the array segment created in the 'Example' section of the ARRREAD documentation.
from pci.arrwrit import arrwrit
file = "TEST.PIX"
arrseg = [2]
format = '' # by default, one decimal number per line
tfile = "TEST_OUT.txt"
arrwrit( file, arrseg, format, tfile )
The output file TEST_OUT.txt has the following data values:
1.000000 2.000000 3.000000
© PCI Geomatics Enterprises, Inc.®, 2026. All rights reserved.