+ Reply to Thread
Results 1 to 5 of 5

Random Sample

  1. #1
    Valued Forum Contributor Saarang84's Avatar
    Join Date
    02-19-2009
    Location
    Chennai, India
    MS-Off Ver
    XL 2003 to 2010
    Posts
    812

    Random Sample

    Hi,

    I've coded a macro that can randomly sample out rows of data from a sheet.

    This macro is used to sample out certain rows from a master sheet full of data (which has 48 columns) based on user names (a column titled LAST_UPDATE_NAME)

    For Example (ref. wkb attached), if for 5 users named Alastor, Catherine, Emma, Julie and Victor for whom i've to choose data from the Dump sheet.

    I need help to design a module in which if i input the no. of samples to be chosen against each name, then that many number of rows has to be chosen for that particular name and copied to a new sheet (probably such sheets can be renamed with the usernames). Also i want to consolidate the copied data from the multiple sheets and consolidate them to one sheet.

    How can this be done? Can someone help me??

    Ranga
    Attached Files Attached Files
    Last edited by Saarang84; 10-18-2009 at 10:13 PM. Reason: Will close this thread and start a new one

  2. #2
    Valued Forum Contributor Saarang84's Avatar
    Join Date
    02-19-2009
    Location
    Chennai, India
    MS-Off Ver
    XL 2003 to 2010
    Posts
    812

    Re: Random Sample


    Hi,
    I've also coded a filtering module that can filter and extract records to a new sheet. The filters can be upto any level, meaning that more filters can be applied to any no. of fields (columns).
    Hope this might be useful.

    Ranga
    Attached Files Attached Files
    Last edited by Saarang84; 10-18-2009 at 10:11 PM.

  3. #3
    Valued Forum Contributor Saarang84's Avatar
    Join Date
    02-19-2009
    Location
    Chennai, India
    MS-Off Ver
    XL 2003 to 2010
    Posts
    812

    Re: Consolidate Sheets into One after Random Sampling

    Hi,
    Had been trying out coding for this.. Here's what i've come up with:
    Please Login or Register  to view this content.
    I'll already have some worksheets in the whole macro that i'm trying to integrate and i'll generate worksheets separately for each user for whom i'll need to choose samples.

    The line indicated above in red needs to be tweaked accordingly in such a way that i'll collate all samples chosen for these users to one master sheet. Simply to say, I don't want to export from all worksheets in the workbook. How can this be done? Can anybody help??

    Ranga
    Last edited by shg; 10-19-2009 at 12:22 AM.

  4. #4
    Valued Forum Contributor Saarang84's Avatar
    Join Date
    02-19-2009
    Location
    Chennai, India
    MS-Off Ver
    XL 2003 to 2010
    Posts
    812

    Random Sample

    Hi Mr. Jaslake,

    Refer our discussion. Please find attached the required document.

    Ranga
    Last edited by Saarang84; 10-18-2009 at 10:12 PM.

  5. #5
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Random Sampling

    Hi Ranga
    I've reviewed your attachment this weekend (you provided the password via personal message). I was somewhat surprised the attachment is password protected. The principle reason I suggested you take this to the Forum was the input you would (could) receive from the wonderful resources available here.
    Alright, I have reviewed your project. You're building what I would call an "Enterprise Solution" that will help you manage your business. I've directed many of these projects during my working career so I'm aware of your daunting challenge. However, in those projects, I defined, and therefore understood, the parameters. Also, I had a team of programmers who understood what I was attempting to accomplish. As I explained, I'm a retired "bean counter". You give me a numbers related issue, I will probably be able to figure it out because I understand the issue.
    I don't know your process. If you had the time, I could be educated. I'm a kinetic learner; you show me (maybe once, maybe 50 times) and I'll figure it out. We don't have the time nor the proximity to do that.
    Your issues are well beyond my knowledge and experience. I would strongly recommend you figure out a way to share your attachment with the Forum. I'm confident the Paul's and shg's and Leith's and many others on this forum will be able to give direction on your issues. However, what you are trying to do is well beyond my knowledge and experience.
    Good hunting. J
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

+ 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.6.0 RC 1