Plotly lines in DjangoWhat is a “slug” in Django?How to combine 2 or more querysets in a Django view?Django - Set Up A Scheduled Job?How do I do a not equal in Django queryset filtering?Does Django scale?How to debug in Django, the good way?Need a minimal Django file upload exampleHow to reset Django admin password?How to check Django versiondifferentiate null=True, blank=True in django

Why did a party with more votes get fewer seats in the 2019 European Parliament election in Denmark?

Does the first version of Linux developed by Linus Torvalds have a GUI?

Word for a small burst of laughter that can't be held back

Is it legal in the UK for politicians to lie to the public for political gain?

You've spoiled/damaged the card

C SIGINT signal in Linux

After the loss of Challenger, why weren’t Galileo and Ulysses launched by Centaurs on expendable boosters?

What happens if you do emergency landing on a US base in middle of the ocean?

What is in `tex.print` or `tex.sprint`?

Payment instructions from HomeAway look fishy to me

Can a magnetic field of an object be stronger than its gravity?

Their answer is discrete, mine is continuous. They baited me into the wrong answer. I have a P Exam question

What happens to foam insulation board after you pour concrete slab?

Pronoun introduced before its antecedent

How is TD(0) method helpful? What good does it do?

Why is the relationship between frequency and pitch exponential?

Etymology of 'calcit(r)are'?

Why don’t airliners have temporary liveries?

Sharing one invocation list between multiple events on the same object in C#

Bent spoke design wheels — feasible?

My coworkers think I had a long honeymoon. Actually I was diagnosed with cancer. How do I talk about it?

What are the words for people who cause trouble believing they know better?

Can you `= delete` a templated function on a second declaration?

Did Darth Vader wear the same suit for 20+ years?



Plotly lines in Django


What is a “slug” in Django?How to combine 2 or more querysets in a Django view?Django - Set Up A Scheduled Job?How do I do a not equal in Django queryset filtering?Does Django scale?How to debug in Django, the good way?Need a minimal Django file upload exampleHow to reset Django admin password?How to check Django versiondifferentiate null=True, blank=True in django






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








0















I have a problem displaying the line graph on the plot.



I've tried using explicit values and it goes well. When I extracted data from a dataframe and replace the explicit values, the lines are no longer appearing. Columns have values as I extracted them...



def graphView(request):
proj = Project.objects.first()
df = pd.read_csv(proj.base_file)
array = df.values
_x = 'Avg. Area Income'
_y = 'Price'
x = df[[_x]].values
y = df[[_y]].values

trace1 = Scatter(x=x, y=y, marker='color': 'red', 'symbol': 104, 'size': 10,
mode="lines", name='1st Trace')

data=Data([trace1])
layout=Layout(title="Meine Daten", xaxis='title':'x1', yaxis='title':'x2')
figure=Figure(data=data,layout=layout)
div = opy.plot(figure, auto_open=False, output_type='div')

context =
'graph': div


return render(request, 'projects/plotly.html', context)


The line graph based from the column values is not displaying...










share|improve this question






























    0















    I have a problem displaying the line graph on the plot.



    I've tried using explicit values and it goes well. When I extracted data from a dataframe and replace the explicit values, the lines are no longer appearing. Columns have values as I extracted them...



    def graphView(request):
    proj = Project.objects.first()
    df = pd.read_csv(proj.base_file)
    array = df.values
    _x = 'Avg. Area Income'
    _y = 'Price'
    x = df[[_x]].values
    y = df[[_y]].values

    trace1 = Scatter(x=x, y=y, marker='color': 'red', 'symbol': 104, 'size': 10,
    mode="lines", name='1st Trace')

    data=Data([trace1])
    layout=Layout(title="Meine Daten", xaxis='title':'x1', yaxis='title':'x2')
    figure=Figure(data=data,layout=layout)
    div = opy.plot(figure, auto_open=False, output_type='div')

    context =
    'graph': div


    return render(request, 'projects/plotly.html', context)


    The line graph based from the column values is not displaying...










    share|improve this question


























      0












      0








      0








      I have a problem displaying the line graph on the plot.



      I've tried using explicit values and it goes well. When I extracted data from a dataframe and replace the explicit values, the lines are no longer appearing. Columns have values as I extracted them...



      def graphView(request):
      proj = Project.objects.first()
      df = pd.read_csv(proj.base_file)
      array = df.values
      _x = 'Avg. Area Income'
      _y = 'Price'
      x = df[[_x]].values
      y = df[[_y]].values

      trace1 = Scatter(x=x, y=y, marker='color': 'red', 'symbol': 104, 'size': 10,
      mode="lines", name='1st Trace')

      data=Data([trace1])
      layout=Layout(title="Meine Daten", xaxis='title':'x1', yaxis='title':'x2')
      figure=Figure(data=data,layout=layout)
      div = opy.plot(figure, auto_open=False, output_type='div')

      context =
      'graph': div


      return render(request, 'projects/plotly.html', context)


      The line graph based from the column values is not displaying...










      share|improve this question
















      I have a problem displaying the line graph on the plot.



      I've tried using explicit values and it goes well. When I extracted data from a dataframe and replace the explicit values, the lines are no longer appearing. Columns have values as I extracted them...



      def graphView(request):
      proj = Project.objects.first()
      df = pd.read_csv(proj.base_file)
      array = df.values
      _x = 'Avg. Area Income'
      _y = 'Price'
      x = df[[_x]].values
      y = df[[_y]].values

      trace1 = Scatter(x=x, y=y, marker='color': 'red', 'symbol': 104, 'size': 10,
      mode="lines", name='1st Trace')

      data=Data([trace1])
      layout=Layout(title="Meine Daten", xaxis='title':'x1', yaxis='title':'x2')
      figure=Figure(data=data,layout=layout)
      div = opy.plot(figure, auto_open=False, output_type='div')

      context =
      'graph': div


      return render(request, 'projects/plotly.html', context)


      The line graph based from the column values is not displaying...







      django






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 25 at 3:28







      dJudge

















      asked Mar 24 at 14:42









      dJudgedJudge

      478




      478






















          0






          active

          oldest

          votes












          Your Answer






          StackExchange.ifUsing("editor", function ()
          StackExchange.using("externalEditor", function ()
          StackExchange.using("snippets", function ()
          StackExchange.snippets.init();
          );
          );
          , "code-snippets");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "1"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55324945%2fplotly-lines-in-django%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55324945%2fplotly-lines-in-django%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

          Swift 4 - func physicsWorld not invoked on collision? The Next CEO of Stack OverflowHow to call Objective-C code from Swift#ifdef replacement in the Swift language@selector() in Swift?#pragma mark in Swift?Swift for loop: for index, element in array?dispatch_after - GCD in Swift?Swift Beta performance: sorting arraysSplit a String into an array in Swift?The use of Swift 3 @objc inference in Swift 4 mode is deprecated?How to optimize UITableViewCell, because my UITableView lags

          Access current req object everywhere in Node.js ExpressWhy are global variables considered bad practice? (node.js)Using req & res across functionsHow do I get the path to the current script with Node.js?What is Node.js' Connect, Express and “middleware”?Node.js w/ express error handling in callbackHow to access the GET parameters after “?” in Express?Modify Node.js req object parametersAccess “app” variable inside of ExpressJS/ConnectJS middleware?Node.js Express app - request objectAngular Http Module considered middleware?Session variables in ExpressJSAdd properties to the req object in expressjs with Typescript