[IUCr Home Page]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

PyCifRW version 3.0



A new version of PyCifRW is now available in
http://anbf2.kek.jp/downloads/.

A quick rundown of new and improved features:

* New StarFile/StarBlock objects supporting reading and writing
arbitrarily deep STAR nested loops (save frame references and global
frames to come later).  In fact, all objects are derived from a basic
STAR LoopBlock object;

* Partial support for item ordering in output - items are output in the
order that they are input;

* Loading from URLs, e.g. 
dd = CifFile("ftp://ftp.iucr.org/pub/cifdics/cifdic.register")

* Built in Python iterators, so the following code snippet is possible
(with dd defined as above):

for dic in dd['validation_dictionaries']: print
dic['_cifdic_dictionary.name']

or even:

coreinfo = filter(lambda a:a['_cifdic_dictionary.name'] ==
'cif_core.dic',dd)

These iterators are even more useful for iterating over STAR nested
loops.


Incompatible changes
====================

* The tuple layout in the argument to AddCifItem has changed for complex
assignments

* GetLoop now returns a CifLoopBlock rather than a list of
(itemname,value) tuples.

More information is available at http://anbf2.kek.jp/CIF
 

-- 
_______________________________________________________________________
James Hester, ANBF                             KEK
e-mail: jrh@anbf2.kek.jp                       Oho 1-1
Phone: +81 298 64 7959                         Tsukuba, Ibaraki 305
  Fax: +81 298 64 7967                         Japan
________________________________________________________________________
_______________________________________________
cif-developers mailing list
cif-developers@iucr.org
http://scripts.iucr.org/mailman/listinfo/cif-developers

Reply to: [list | sender only]


Copyright © International Union of Crystallography

IUCr Webmaster