Private
Public Access
1
0

bugfix binsize 0

This commit is contained in:
Sander Roosendaal
2017-07-06 17:18:29 +02:00
parent 14e523ed4f
commit c6aba2a7e5
2 changed files with 7 additions and 3 deletions

View File

@@ -1174,8 +1174,8 @@ def interactive_multiflex(datadf,xparam,yparam,groupby,extratitle='',
yparamname = axlabels[yparam]
if xparam=='distance':
xaxmax = datadf['x1'].max()
xaxmin = datadf['x1'].min()
xaxmax = datadf['x'].max()
xaxmin = datadf['x'].min()
else:
xaxmax = yaxmaxima[xparam]
xaxmin = yaxminima[xparam]

View File

@@ -3456,6 +3456,8 @@ def multiflex_view(request,userid=0,
groupby = chartform.cleaned_data['groupby']
binsize = chartform.cleaned_data['binsize']
if binsize <= 0:
binsize = 1
spmmin = chartform.cleaned_data['spmmin']
spmmax = chartform.cleaned_data['spmmax']
@@ -3569,6 +3571,8 @@ def multiflex_view(request,userid=0,
groupby = chartform.cleaned_data['groupby']
binsize = chartform.cleaned_data['binsize']
if binsize <= 0:
binsize = 1
spmmin = chartform.cleaned_data['spmmin']
spmmax = chartform.cleaned_data['spmmax']
@@ -3616,7 +3620,7 @@ def multiflex_view(request,userid=0,
datadf.dropna(axis=0,how='any',inplace=True)
datemapping = {
w.id:w.date for w in workouts
}