With the interpolateNulls option set to true, this should be enough to cause interpolation. Does it work correctly without the curveType: 'function' option? If so, then that is a bug.
Otherwise, it is difficult to tell what is happening without seeing your data. Could you inline a sufficient sample of your data? Maybe create a jsfiddle example. On Tue, Feb 7, 2017 at 6:23 PM, Elijah Gregory <ejgreg...@gmail.com> wrote: > Interpolate the points you want and include them in your data passed to > the API. > > ~EG > > On Feb 7, 2017 4:22 PM, "Wilson Rogério Braun" <braun0...@gmail.com> > wrote: > >> Because in the code the line graph when there is no data the line goes >> down to zero, instead of following the trend of the previous values? >> <script type="text/javascript" src="https://www.gstatic.com/c >> harts/loader.js"></script> >> <script type="text/javascript" src="//ajax.googleapis.com/aja >> x/libs/jquery/1.10.2/jquery.min.js"></script> >> <script type="text/javascript"> >> var value; >> google.charts.load('current', { packages: ['table', 'corechart'] }); >> google.charts.setOnLoadCallback(function () { drawtable('') }); >> google.charts.setOnLoadCallback(function () { drawChart('') }); >> $(document).ready(function () { >> value = $("#animal").val(); >> if (value != undefined) { >> drawtable(value); >> } >> $("#animal").change(function () { >> value = $(this).val(); >> drawtable(value); >> }); >> }); >> >> var url = '/Programa_Nutricao/Principal/EvolucaoTemperatura/' + codigo; >> $.get(url, {}, >> function (data) { >> var tdata = new google.visualization.DataTable(); >> tdata.addColumn('date', 'data_atividade'); >> tdata.addColumn('number', 'Temp. Corporal'); >> tdata.addColumn('number', 'Temp. Retal'); >> for (var i = 0; i < data.length; i++) { >> if (data[i].data_atividade != null) >> >> tdata.addRow([ToJavaScriptDate(data[i].data_atividade), >> parseFloat(data[i].temperaturaCorporal), parseFloat(data[i].temperatura >> Retal)]); >> } >> var options = { >> width: 700, >> height: 500, >> vAxis: { title: "Temperatura ºC", minValue: '30', >> maxValue: '45' }, >> hAxis: { title: "DATA", textStyle: { fontSize: 10 } >> }, >> legend: { position: 'bottom' }, >> curveType: 'function', >> interpolateNulls: true >> }; >> var chart = new google.visualization.LineChart >> (document.getElementById('EvolucaoTemperatura')); >> chart.draw(tdata, options); >> }); >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Google Chart API" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to google-chart-api+unsubscr...@googlegroups.com. >> To post to this group, send email to google-chart-api@googlegroups.com. >> Visit this group at https://groups.google.com/group/google-chart-api. >> For more options, visit https://groups.google.com/d/optout. >> > -- > You received this message because you are subscribed to the Google Groups > "Google Chart API" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to google-chart-api+unsubscr...@googlegroups.com. > To post to this group, send email to google-chart-api@googlegroups.com. > Visit this group at https://groups.google.com/group/google-chart-api. > For more options, visit https://groups.google.com/d/optout. > -- Daniel LaLiberte <https://plus.google.com/100631381223468223275?prsrc=2> dlalibe...@google.com <dlalibe...@google.com> 5CC, Cambridge MA -- You received this message because you are subscribed to the Google Groups "Google Chart API" group. To unsubscribe from this group and stop receiving emails from it, send an email to google-chart-api+unsubscr...@googlegroups.com. To post to this group, send email to google-chart-api@googlegroups.com. Visit this group at https://groups.google.com/group/google-chart-api. For more options, visit https://groups.google.com/d/optout.