climate-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jo...@apache.org
Subject svn commit: r1506808 - /incubator/climate/branches/RefactorInput/ocw/dataset.py
Date Thu, 25 Jul 2013 02:25:05 GMT
Author: joyce
Date: Thu Jul 25 02:25:05 2013
New Revision: 1506808

URL: http://svn.apache.org/r1506808
Log:
CLIMATE-219 - Add name attribute to Dataset

Modified:
    incubator/climate/branches/RefactorInput/ocw/dataset.py

Modified: incubator/climate/branches/RefactorInput/ocw/dataset.py
URL: http://svn.apache.org/viewvc/incubator/climate/branches/RefactorInput/ocw/dataset.py?rev=1506808&r1=1506807&r2=1506808&view=diff
==============================================================================
--- incubator/climate/branches/RefactorInput/ocw/dataset.py (original)
+++ incubator/climate/branches/RefactorInput/ocw/dataset.py Thu Jul 25 02:25:05 2013
@@ -26,7 +26,7 @@ import logging
 class Dataset:
     '''Container for a dataset's attributes and data.'''
 
-    def __init__(self, lats, lons, times, values, variable=None):
+    def __init__(self, lats, lons, times, values, variable=None, name=""):
         '''Default Dataset constructor
 
         :param lats: One dimensional numpy array of unique latitude values.
@@ -41,12 +41,15 @@ class Dataset:
         :type values: numpy array
         :param variable: Name of the value variable.
         :type variable: string
+        :param name: An optional string name for the Dataset.
+        :type variable: string
         '''
         self.lats = lats
         self.lons = lons
         self.times = times
         self.values = values
         self.variable = variable
+        self.name = name
 
     def spatial_boundaries(self):
         '''Calculate the spatial boundaries.



Mime
View raw message