I'm struggling to get my head around how I can load a pedigree from sqlite.
Where do I enter the name of the animal I want to retrieve from the database?
Lets say I want to run the below script, I'm looking for a horse in my database called Verve (there is more than one horse with this name also).
from PyPedal import pyp_newclasses
options = {}
options['messages'] = 'verbose'
options['pedfile'] = 'Verve.ped'
options['pedformat'] = 'ASDx'
options['database_name'] = 'pypedal'
options['dbtable_name'] = 'horses_pp'
options['database_type'] = 'sqlite'
if __name__ == '__main__':
example = pyp_newclasses.loadPedigree(options,pedsource='db')
example.metadata.printme()
I have imported my data into the default sqlite database for PyPedal
animalID integer UNIQUE, animalName varchar(128), sireID integer, damID integer, generation real, infGeneration real, birthyear integer, sex char(1), coi real, founder char(1), ancestor char(1), originalID text, renumberedID integer, pedgreeComp real, breed text, age real, alive char(1), num_sons integer, num_daus integer, num_unk integer
"122499" "164141" "Verve" "41674" "103037" "NULL" "NULL" "2001" "D" "NULL" "NULL" "NULL" "NULL" "NULL" "NULL" "NULL" "NULL" "NULL" "NULL" "NULL" "NULL"
I'm struggling to get my head around how I can load a pedigree from sqlite.
Where do I enter the name of the animal I want to retrieve from the database?
Lets say I want to run the below script, I'm looking for a horse in my database called Verve (there is more than one horse with this name also).
I have imported my data into the default sqlite database for PyPedal