Hello,
Could i use a variable defined in a function in another function? I have now: def DatasetToSubset(file, LatUpbound, LatLowBound, LonUpBound, LonLowBound): nc=netCDF4.Dataset(file) lats=nc.variables['lat'][:]; lons=nc.variables['lon'][:] latselect=np.logical_and(lats > LatLowBound, lats < LatUpBound) lonselect=np.logical_and(lon > LonLowBound, lon < LonUpBound) data=nc.variables['Runoff'][1000, latselect, lonselect] return data; return latselect; return lonselect So, i want to use latselect and lonselect in a different function where i interpolate for the subsetted area. Nils _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor