+ Reply to Thread
Results 1 to 9 of 9

Thread: Selecting every nth (e.g. 10th) row for a graph

  1. #1
    Registered User
    Join Date
    07-20-2009
    Location
    Maidstone
    MS-Off Ver
    Excel 2003
    Posts
    5

    Red face Selecting every nth (e.g. 10th) row for a graph

    Hello,

    I have too many data points (time, value) for a graph.

    I want to select every 10th or 20th point to plot. Any ideas how I can achieve this please.

    I have tried selection
    row 1
    row 10
    row 20

    and extending it but this then selects 2, 11, 21 !!

    Help please !!

    Thanks, Mel

  2. #2
    Registered User
    Join Date
    08-30-2005
    Posts
    9

    Re: Selecting every nth (e.g. 10th) row for a graph

    Press the CTRL key and then highlight the data points. Excel should
    pick up the fields you want.

  3. #3
    Registered User
    Join Date
    07-20-2009
    Location
    Maidstone
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Selecting every nth (e.g. 10th) row for a graph

    But I have 33,000 rows! So manual selection is out.

    I am trying to do this:

    row1>>>>>>>>link>>>>>>>>>row 1 (time, value)
    row2>>>>>>>>>>>>>>>>>>>row10(time, value)
    ..>>>>>>>>>>>>>>>>>>>>>row20 (time, value)
    row10
    ..
    ..
    row20

    so that I can easily graph the row1, row10, row20 pairs as they form a contiguous dataset I can lasoo.
    Last edited by Mel_P; 07-20-2009 at 05:06 PM.

  4. #4
    Registered User
    Join Date
    07-20-2009
    Location
    Maidstone
    MS-Off Ver
    Excel 2003
    Posts
    5

    plotting every 20th (say) value from 33,000 points

    I have 33,000 pairs of values from a logger.

    -Time, concentration

    How do I plot (or extract) every 20th pair of value (or some other defined interval)?

    Any ideas please (macro, VBA NOT manual selection)

    Thanks. Mel

  5. #5
    Forum Guru shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2007, 2010
    Posts
    25,736

    Re: Selecting every nth (e.g. 10th) row for a graph

    Threads merged -- there's no need to start a new one. Carry on.
    Microsoft MVP - Excel
    Entia non sunt multiplicanda sine necessitate

  6. #6
    Registered User
    Join Date
    07-20-2009
    Location
    Maidstone
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Selecting every nth (e.g. 10th) row for a graph

    Thanks mod - apols.

  7. #7
    Forum Guru shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2007, 2010
    Posts
    25,736

    Re: Selecting every nth (e.g. 10th) row for a graph

    Any reason not to do this with a simple formula?

    If you really want code, post a workbook that shows input (not all 30000 rows) and desired output (like, where it goes).
    Microsoft MVP - Excel
    Entia non sunt multiplicanda sine necessitate

  8. #8
    Registered User
    Join Date
    07-20-2009
    Location
    Maidstone
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Selecting every nth (e.g. 10th) row for a graph

    Posted it on microsoft excel forum and a response telling me to use the INDIRECT function worked.

    So solved!

  9. #9
    Forum Guru shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2007, 2010
    Posts
    25,736

    Re: Selecting every nth (e.g. 10th) row for a graph

    Well done.

    Be aware that INDIRECT is a volatile function, so it recalculates every time anything changes. So is OFFSET, which is another alternative.

    A better choice would be a solution that used INDEX.
    Microsoft MVP - Excel
    Entia non sunt multiplicanda sine necessitate

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.2.0