pysal

This Page

IOHandlers.geoda_txt — Geoda_txt Plugin for PySAL’s FileIO System

New in version 1.0.

class pysal.core.IOHandlers.geoda_txt.GeoDaTxtReader(*args, **kwargs)

DataTable provides additional functionality to FileIO for data table file tables FileIO Handlers the provide data tables should subclass this instead of FileIO

Methods

by_col
by_row
cast
check
close
flush
get
getType
next
open
read
seek
tell
truncate
write
class by_col(parent)
class GeoDaTxtReader.by_row(parent)
GeoDaTxtReader.cast(key, typ)
cast key as typ
classmethod GeoDaTxtReader.check()
Prints the contents of the registry
GeoDaTxtReader.close()
GeoDaTxtReader.flush()
GeoDaTxtReader.get(n)
Seeks the file to n and returns n If .ids is set n should be an id, else, n should be an offset
static GeoDaTxtReader.getType(dataPath)
Parse the dataPath and return the data type
GeoDaTxtReader.ids
GeoDaTxtReader.next()
A FileIO object is its own iterator, see StringIO
classmethod GeoDaTxtReader.open(*args, **kwargs)
Alias for FileIO()
GeoDaTxtReader.rIds
GeoDaTxtReader.read(n=-1)
Read at most n objects, less if read hits EOF if size is negative or omitted read all objects until EOF returns None if EOF is reached before any objects.
GeoDaTxtReader.seek(n)
Seek the FileObj to the beginning of the n’th record, if ids are set, seeks to the beginning of the record at id, n
GeoDaTxtReader.tell()
Return id (or offset) of next object
GeoDaTxtReader.truncate(size=None)
Should be implemented by subclasses and redefine this doc string
GeoDaTxtReader.write(obj)
Must be implemented by subclasses that support ‘w’ subclasses should increment .pos subclasses should also check if obj is an instance of type(list) and redefine this doc string