Results 1 to 5 of 5

Math Help - Smooth graph matlab

  1. #1
    Senior Member
    Joined
    Oct 2008
    Posts
    393

    Smooth graph matlab

    Hi i have a graph (please see attatched).

    But i want them to be smooth curves.

    My teacher has told me to reduce bin sizes.

    How do i do this?

    Thanks Adam
    Attached Thumbnails Attached Thumbnails Smooth graph matlab-football-league-comparison-graph.pdf  
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Grand Panjandrum
    Joined
    Nov 2005
    From
    someplace
    Posts
    14,972
    Thanks
    4
    Quote Originally Posted by adam_leeds View Post
    Hi i have a graph (please see attatched).

    But i want them to be smooth curves.

    My teacher has told me to reduce bin sizes.

    How do i do this?

    Thanks Adam
    Sort the data in a data set (call the data: x) put y=(1:length(x))/length(x) then plot(x,y)

    CB
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Senior Member
    Joined
    Oct 2008
    Posts
    393
    Quote Originally Posted by CaptainBlack View Post
    Sort the data in a data set (call the data: x) put y=(1:length(x))/length(x) then plot(x,y)

    CB
    Bit confused.

    I already have x as a set of values. And y as a set of values.
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Senior Member
    Joined
    Oct 2008
    Posts
    393
    In fact that's what i've already done.

    PR = sort(x);
    x=[1:1:366];
    a=x/366;
    plot(PR,a)

    and it comes out like that
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Grand Panjandrum
    Joined
    Nov 2005
    From
    someplace
    Posts
    14,972
    Thanks
    4
    Quote Originally Posted by adam_leeds View Post
    In fact that's what i've already done.

    PR = sort(x);
    x=[1:1:366];
    a=x/366;
    plot(PR,a)

    and it comes out like that
    So why are you talking about bin sizes, there is no binning involved?

    CB
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Replies: 1
    Last Post: March 26th 2011, 10:10 AM
  2. Replies: 1
    Last Post: October 7th 2010, 09:54 PM
  3. matlab plotting graph need help
    Posted in the Math Software Forum
    Replies: 1
    Last Post: August 7th 2010, 12:27 AM
  4. MATLAB finding graph
    Posted in the Math Software Forum
    Replies: 5
    Last Post: December 5th 2009, 09:42 AM
  5. plotting a graph in matlab
    Posted in the Math Software Forum
    Replies: 3
    Last Post: March 21st 2009, 03:11 PM

Search Tags


/mathhelpforum @mathhelpforum