statistics-n-nnn tags
From the DTML manual : variance-nnn : The variance of numeric values computed with a degrees of freedom equal to the (count - 1). variance-n-nnn : The variance of numeric values computed with a degrees of freedom equal to the count. standard-deviation-nnn : The standard deviation of numeric values computed with a degrees of freedom equal to the (count - 1). standard-deviation-n-nnn : The standard deviation of numeric values computed with a degrees of freedom equal to the count. So I try: <!--#var standard-deviation-EGO --> which works, however, <!--#var standard-deviation-2-EGO --> provides: Traceback (innermost last): File "<stdin>", line 1, in ? File "pedsys.py", line 218, in summary return HTML(html)(self) File "./DT_String.py", line 513, in __call__ File "/usr/pkg/zope/lib/python/DocumentTemplate/DT_In.py", line 678, in renderwob try: append(render(section, md)) KeyError: standard-deviation-2-EGO All statistics-n-nnn forms result in a key error regardless of how/ where I use them. Am I misreading the manual on how to use them? I'm running Zope 1.10.2 but I peeked at 1.11.0pr1 and saw that there have been no changes to DT_InSV.py between the two versions (1.10.2 and 1.11.0pr1). Thanks Kent
Kent - I think you're misunderstanding the names of the tags. To quote from the source: statistic_names=( 'total', 'count', 'min', 'max', 'median', 'mean', 'variance', 'variance-n','standard-deviation', 'standard-deviation-n', )
So I try: <!--#var standard-deviation-EGO --> which works, however, <!--#var standard-deviation-2-EGO -->
should probably be: <!--#var standard-deviation-n-EGO --> I'd test this, but I don't have an appropriate context handy. Hope this helps, Ross -- Ross J. Reedstrom, Ph.D., <reedstrm@rice.edu> NSBRI Research Scientist/Programmer Computer and Information Technology Institute Rice University, 6100 S. Main St., Houston, TX 77005
participants (2)
-
kent@tiamat.goathill.org -
Ross J. Reedstrom