File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -1452,7 +1452,9 @@ def writeXref(self):
1452
1452
def writeInfoDict (self ):
1453
1453
"""Write out the info dictionary, checking it for good form"""
1454
1454
1455
- is_date = lambda x : isinstance (x , datetime )
1455
+ def is_date (x ):
1456
+ return isinstance (x , datetime )
1457
+
1456
1458
check_trapped = (lambda x : isinstance (x , Name ) and
1457
1459
x .name in ('True' , 'False' , 'Unknown' ))
1458
1460
keywords = {'Title' : is_string_like ,
Original file line number Diff line number Diff line change @@ -2886,7 +2886,9 @@ def test_callable_covariance_dataset(self):
2886
2886
np .random .seed (8765678 )
2887
2887
n_basesample = 50
2888
2888
multidim_data = [np .random .randn (n_basesample ) for i in range (5 )]
2889
- callable_fun = lambda x : 0.55
2889
+
2890
+ def callable_fun (x ):
2891
+ return 0.55
2890
2892
kde = mlab .GaussianKDE (multidim_data , bw_method = callable_fun )
2891
2893
assert_equal (kde .covariance_factor (), 0.55 )
2892
2894
You can’t perform that action at this time.
0 commit comments