@@ -14,27 +14,32 @@ query, use:
1414
1515.. code-block :: python
1616
17- >> > from astroquery import lamda
18- >> > lamda.print_mols()
17+ >> > from astroquery.lamda import Lamda
18+ >> > lamda.molecule_dict
1919
20- A query type must be specified among ``'erg_levels' `` for energy levels,
21- ``'rad_trans' `` for radiative transitions, or ``'coll_rates' `` for collisional
22- rates. Example queries are show below:
20+ The dictionary is created dynamically from the LAMDA website the first time it
21+ is called, then cached for future use. If there has been an update and you
22+ want to reload the cache, you can find the cache file `molecules.json ` and
23+ remove it:
2324
2425.. code-block :: python
2526
26- >> > erg_t = lamda.query(mol = ' co' , query_type = ' erg_levels' )
27- >> > rdt_t = lamda.query(mol = ' co' , query_type = ' rad_trans' )
28- >> > clr_t = lamda.query(mol = ' co' , query_type = ' coll_rates' )
27+ >> > Lamda.cache_location
28+ u ' /Users/your_username/.astropy/cache/astroquery/Lamda'
29+ >> > Lamda.moldict_path
30+ u ' /Users/your_username/.astropy/cache/astroquery/Lamda/molecules.json'
31+ >> > os.remove(Lamda.moldict_path)
2932
30- Catalogs are returned as `~astropy.table.Table ` instances. Often molecules have
31- collisional rates calculate for more than one collisional partner, specify the
32- order of the partner in the datafile using the ``coll_partner_index `` parameter:
33+
34+ You can query for any molecule in that dictionary.
3335
3436.. code-block :: python
3537
36- >> > clr_t0 = lamda.query(mol = ' co' , query_type = ' coll_rates' , coll_partner_index = 0 )
37- >> > clr_t1 = lamda.query(mol = ' co' , query_type = ' coll_rates' , coll_partner_index = 1 )
38+ >> > collrates,radtransitions,enlevels = Lamda.query(mol = ' co' )
39+
40+ Catalogs are returned as `~astropy.table.Table ` instances, except for
41+ `collrates `, which is a dictionary of tables, with one table for each
42+ collisional partner.
3843
3944Reference/API
4045=============
0 commit comments