Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7507477
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T22:29:42+00:00 2026-05-29T22:29:42+00:00

Hello I have a Google Visualisation Line chart like this… <script type=text/javascript src=https://www.google.com/jsapi></script> <script

  • 0

Hello I have a Google Visualisation Line chart like this…

<script type="text/javascript" src="https://www.google.com/jsapi"></script>

<script type="text/javascript">

    google.load("visualization", "1", { packages: ["corechart"] });

    google.setOnLoadCallback(drawChart);

    function drawChart() {

        var data = new google.visualization.DataTable();

        data.addColumn('string', 'Week');

        data.addColumn('number', 'Points');

        data.addRows([['12/26/2011 12:00:00 AM', 0], ['1/2/2012 12:00:00 AM', 0], ['1/9/2012 12:00:00 AM', 0], ['1/16/2012 12:00:00 AM', 0]]);



        var options = {

            width: 800, height: 400,

            hAxis: {title: 'Week'},

            vAxis: {title: 'Points', minValue: 0, baseline: 0},

            title: 'Activity'

        };



        var chart = new google.visualization.LineChart(document.getElementById('chart_div'));

        chart.draw(data, options);

    }

</script>



<div id="chart_div"></div>

How can I set the vertical axis to start from 0 (now it starts from -1 and goes to 1) (my vertical axis values are always>0). Also they are always natural numbers how can I make the vertical axes to only show natural numbers on the scale (no fractional numbers)?
Thank you,
Bogdan

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T22:29:43+00:00Added an answer on May 29, 2026 at 10:29 pm

    in var options , you can add this :

          vAxis: {
            viewWindowMode: 'explicit',
            viewWindow: {
              //max: 8000,
              min: 0,
            },
            gridlines: {
              count: 18,  //set kind of step (max-min)/count
            }
          }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this simple hello world version of a google map api javascript v3
Hello i have this form filling javascript: function onLine(code,nn) { document.writeform.bericht.value+=code; document.writeform.bericht.focus(); document.writeform.nickname.value+=nn; write1();
Hello I want to have a % in my google chart data i have
It just appears like this in Google Chrome: <html> <head> <title>Hello World!</title> </head> <body>
This is a script I have for a google spreadsheet. It all works except
I have a plain text, say, Hello how are you, please visit 'http://google.com' .
Hello I have been having trouble with this for a while now. I have
Hello I have this list that i am working on. When i move the
I have no idea why this is happening; some Google searches have led me
Hello I have a multigeometry How has a Style like a rollover when you

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.