+ Reply to Thread
Results 1 to 6 of 6

LookUp values from two columns and calculate accordingly

  1. #1
    Forum Contributor
    Join Date
    05-06-2015
    Location
    Sri Lanka
    MS-Off Ver
    2016, 2007
    Posts
    135

    LookUp values from two columns and calculate accordingly

    Hello,

    I would be very grateful if somebody could kindly look in to my problem.

    Here is the story, I have to make a dummy progress data file, instead of just creating random data I would prefer to generate some smart data.

    We are (non profit) an agricultural firm, our field officers (located in 5 districts) are giving farmers some planting materials (3 crop types) to cultivate (for free, but it doesn't matter)

    I need to make a dummy progress data and I need to generate random-between values where min and max values based on district and crop.

    a sample data file is attached. any help will be highly appreciated. Thank you.
    Attached Files Attached Files

  2. #2
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: LookUp values from two columns and calculate accordingly

    Taking a guess here. I added two columns to the main table on Sheet1...Min and Max and in the progress subtracted the Min from the Max for each row. I then created a Pivot Table.
    There is no real indication of how you are gathering your statistics so this is my best guess at the moment.
    Attached Files Attached Files
    <---------If you like someone's answer, click the star to the left of one of their posts to give them a reputation point for that answer.
    Ron W

  3. #3
    Forum Contributor
    Join Date
    05-06-2015
    Location
    Sri Lanka
    MS-Off Ver
    2016, 2007
    Posts
    135

    Re: LookUp values from two columns and calculate accordingly

    Quote Originally Posted by newdoverman View Post
    Taking a guess here. I added two columns to the main table on Sheet1...Min and Max and in the progress subtracted the Min from the Max for each row.
    Thanks for your time. what I need to generate is random data between min and max values for respected district and crop accordingly. This is a dummy data to create and demonstrate a dash board. Not measuring Progress by Min and Max values. It's just to create more practical values (based on our real field expected values) rather than just creating a random data for each district and crop uniformly.

    Sorry for any inconvenience because of my poor writing skills to express my need more accurately. English is not my first language.

  4. #4
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: LookUp values from two columns and calculate accordingly

    To generate values between the min and max values you could use RANDBETWEEN.
    =RANDBETWEEN(MIN VALUE, MAX VALUE)
    To fill in the main table with values between the MIN and MAX values in the smaller table. This will do that. Enter in H2 with Ctrl + Shift + Enter. This is an ARRAY FORMULA.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files

  5. #5
    Forum Contributor
    Join Date
    05-06-2015
    Location
    Sri Lanka
    MS-Off Ver
    2016, 2007
    Posts
    135

    Re: LookUp values from two columns and calculate accordingly

    fantastic. No words to express my thankfulness.

  6. #6
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: LookUp values from two columns and calculate accordingly

    Glad to help. Thanks for the feedback.

+ 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. Lookup in two columns between two values
    By YasserKhalil in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-07-2015, 12:25 PM
  2. Replies: 3
    Last Post: 04-08-2014, 03:11 AM
  3. Calculate values in two columns based on a value in a third column
    By rdowney79 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-14-2014, 10:05 AM
  4. [SOLVED] Lookup multiple valvues + Calculate values = Total
    By wintheranders in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 08-01-2013, 03:19 AM
  5. calculate MAX if certain values are met in other columns
    By aaron_burr in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-05-2012, 07:26 AM
  6. Fomula to Calculate Multiple Columns with TIED Values
    By lumo1985 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-02-2008, 01:23 AM
  7. Looking-up Columns w/calc'd Values ONLY to Calculate Average
    By sony654 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 04-21-2006, 01:25 AM

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