+ Reply to Thread
Results 1 to 18 of 18

Dependent Table Analysis Problem

  1. #1
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Dependent Table Analysis Problem

    I am clueless as to even attempting this type of problem, but I am trying to figure out a way to automatically have excel to pick the appropriate group based on 1 or 2 options chosen. I work for a drug testing company and when the analysts are typing in patient data and choosing the different drugs that need to be tested for, I want excel to return in the appropriate cell the best drug panel or panels to run the patients on. For example:

    __________Panel
    _______1__2__3__4
    Drug 1__X__X
    Drug 2__X__X
    Drug 3__X__X__X
    Drug 4_____X__X
    Drug 5_____X__X__X
    Drug 6________X__X
    Drug 7___________X
    Drug 8___________X
    Drug 9________x__X
    Drug 10_______X__X


    As you can see, Panel 1 processes 3 different drug types, whereas Panel 2 processes those same three drugs plus 2 others. Ideally if the analysts were to just choose drug 1 then the quickest panel to process would be panel 1 because it is shorter, hence requiring less time to run. However, usually 2 drugs are tested for. This is where my excel has lost me. If Drug 2 and Drug 5 were Chosen for a particular patient then ideally panel 2 would need to be ran because it kills two birds with one stone. But lets say that Drug 2 and Drug 8 were chosen, then I would need excel to return Panel 1 (which is shorter than Panel 2) and Panel 4. I have a userform setup that allows for up to two drugs to be chosen from drop down boxes, each using the same comprehensive drug list. If possible, I would like for excel to return the appropriate panel(s) in a box, possibly the list box, on the userform following the selection of the drug(s) to be tested for. If not, then is there some type of way for excel to analyze the table and spit out something that I could work with. I would greatly appreciate any help, It would be a life saver.
    Last edited by RaydenUK; 03-26-2014 at 02:25 PM.

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,724

    Re: Dependent Table Analysis Problem

    Quote Originally Posted by RaydenUK View Post
    As you can see, ...
    No, we can't see, because that hasn't formatted very well on the post. Please attach a sample workbook, then it should be clearer (the FAQ describes how to).

    Pete

  3. #3
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Dependent Table Analysis Problem

    Example Panel vs Drug Table.xlsx

    Sorry about that, but I have attached a workbook that has this table. The actual version of this table has about 60+ drugs and 17 panels. If there is a formula or function that can analyze the results of this data and return the appropriate panel(s) then I could incorporate it into my userform as needed. Thanks.

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Dependent Table Analysis Problem

    Is there an implicit assumption that the cost of a panel is linearly proportional to the number of drugs for which it tests?
    Entia non sunt multiplicanda sine necessitate

  5. #5
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Dependent Table Analysis Problem

    Cost is not the factor, runtime is what we are concerned with. Panel size is directly proportional to runtime, where the more drugs a panel tests for, the longer it takes for the LC/MS instrument to run.

  6. #6
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Dependent Table Analysis Problem

    Then one needs to know the run-time for each panel so there is an objective function to minimize.

    Cost is a generic term.

  7. #7
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Dependent Table Analysis Problem

    Then lets say the runtime for each panel is (in seconds) 60, 90, 120, and 100 respectively. Just to clarify, if drug 1 is being tested for, then I have 3 options: panels 1, 2, and 3. After one of the 3 panels is chosen (preferably panel 1), then all of the drugs in that panel will be ran as well. Therefore, if panel 1 only runs 3 different drugs compared to the other two panels that run 5 and 6 drugs, then panel 1 would be the fastest due to having to run less. I'm sorry if I am not very helpful, I am still new to excel. Thank you for the replies though.
    Last edited by RaydenUK; 03-26-2014 at 09:42 PM.

  8. #8
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Dependent Table Analysis Problem

    Why not just break down and post the whole thing?

    Trust us to handle the complexity, because you aren't going to get far with this approach.

  9. #9
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Dependent Table Analysis Problem

    Userform Project forum post.xlsm

    Ok here is my original Workbook. In the Master tab I have the drugs and their panels laid out in several different ways. Ultimately I would like for the panel to be automatically selected in the userform (in the row "optimal panel") when the analysts are putting in the drug(s) in the drop boxes for "screened anlaytes 1" and "screened analytes 2".

  10. #10
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Dependent Table Analysis Problem

    There's a lot of unexplained data on that sheet.

    What is needed is your prior table that lists the drugs tested by each panel, and the cost (however you define that) of each panel.

  11. #11
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Dependent Table Analysis Problem

    The table is in range D1:R54 in the master tab. Column D lists the drugs and row 1 is the different panels that are defined as letters. Cost in this case is the amout of drugs that each panel tests for. So if panel A tests for 5 different drugs then the cost could be 5 and same with panel B that may test for 8 drugs, its cost would be 8. I hope that clears it up a little better.

  12. #12
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Dependent Table Analysis Problem


  13. #13
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Dependent Table Analysis Problem

    Wow that table does exactly what I was wanting it to do. Thank you so much for your help! Sorry I didn't understand the cost concept, my understanding of Excel is basic. This table will really come in handy at our company. I wonder, though, if there is a way to tie this chart in with the userform that I built on the 'Repeat Data' tab? Would it be possible to have it autofill the box labeled "optimal panel" after selecting the analytes (drugs) from the drop boxes in the userform. If only one panel is needed then return that panel or return multiple panels if need, possibly separated with a comma. Thank you.

  14. #14
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Dependent Table Analysis Problem

    Sorry, no, not by me. Userforms are just a lot of niggling work.

  15. #15
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Dependent Table Analysis Problem

    I did add a comma-delimited list output, though. Same link.

  16. #16
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Dependent Table Analysis Problem

    Where is the output shown at? I see the X's at the top of the table. Is that what you're referring to?

  17. #17
    Forum Contributor
    Join Date
    03-26-2014
    Location
    Kentucky
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Dependent Table Analysis Problem

    Thank you again for all your help, the list output will work perfect. I am forever in your debt!

  18. #18
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Dependent Table Analysis Problem

    You're welcome. Interesting problem.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Dependent Combo Box Problem!
    By Paperboy9 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-21-2013, 05:58 AM
  2. Dependent list problem
    By Exceltrouble in forum Excel General
    Replies: 4
    Last Post: 04-27-2011, 03:43 AM
  3. Dependent List problem
    By jennieS in forum Excel General
    Replies: 6
    Last Post: 01-08-2010, 12:09 PM
  4. problem with data analysis
    By godel in forum Excel General
    Replies: 1
    Last Post: 08-19-2009, 12:00 PM
  5. data analysis problem
    By smalllittle in forum Excel - New Users/Basics
    Replies: 3
    Last Post: 03-20-2009, 09:33 PM

Tags for this Thread

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