+ Reply to Thread
Results 1 to 9 of 9

Transpose and return a row values in a columns limited to one unique and one duplicate

  1. #1
    Forum Contributor
    Join Date
    08-19-2020
    Location
    Dubai
    MS-Off Ver
    Office365
    Posts
    131

    Transpose and return a row values in a columns limited to one unique and one duplicate

    Hi,

    Required a formula help for transpose and return a row values in a columns limited to one unique and one duplicate without blanks, as based on data available (column B).

    Sample sheet enclosed with expected results.


    Thanks,

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,970

    Re: Transpose and return a row values in a columns limited to one unique and one duplicate

    Maybe like this:

    =LET(d,B3:B26,u,UNIQUE(FILTER(d,d<>"")),Cu,COUNTA(u),s,INT(SEQUENCE(,2*Cu,1,0.5)),INDEX(TRANSPOSE(u),,s))
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  3. #3
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Transpose and return a row values in a columns limited to one unique and one duplicate

    Nice, Glenn!

    Since the values are numeric, perhaps we can simplify?

    =LET(α,B3:B25,β,UNIQUE(α),SMALL(β,1+QUOTIENT(SEQUENCE(,2*COUNT(β),0),2)))

    Regards
    Click * below if this answer helped

    Advanced Excel Techniques: http://excelxor.com/

  4. #4
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,970

    Re: Transpose and return a row values in a columns limited to one unique and one duplicate

    XOR LX... are you still there??

    Nice... but I could do with a bit of help understanding it. How does SMALL manage to ignore the zero in this context? The smallest value is zero... or am I being dense?? I guess this also depends on the numbers being in ascending order, too...
    Attached Images Attached Images

  5. #5
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Transpose and return a row values in a columns limited to one unique and one duplicate

    Quote Originally Posted by Glenn Kennedy View Post
    How does SMALL manage to ignore the zero in this context?
    No, that's just the Evaluate Formula window unhelpfully rendering the blanks as numerical zeroes in that step, but then evaluating them correctly as blanks in the final evaluation.

    Quote Originally Posted by Glenn Kennedy View Post
    I guess this also depends on the numbers being in ascending order, too...
    Eh? Why?

    Cheers

  6. #6
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,970

    Re: Transpose and return a row values in a columns limited to one unique and one duplicate

    So to quote a former US President... it's "FAKE NEWS!" Evaluate formula is so useful... it's pity that this is another example of its failings... Many thanks for the explanation, though!

    By ascending order I meant that if the 1214s were all replaced by 8888, they would appear in 3rd place (our of sequence), being preceeded by 1450 & 1560.

  7. #7
    Forum Guru Bo_Ry's Avatar
    Join Date
    09-10-2018
    Location
    Thailand
    MS-Off Ver
    MS 365
    Posts
    7,211

    Re: Transpose and return a row values in a columns limited to one unique and one duplicate

    Please try

    =LET(z,B3:B25,y,B4:B26,TRANSPOSE(FILTER(z,z*(z<>y))))

  8. #8
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Transpose and return a row values in a columns limited to one unique and one duplicate

    Quote Originally Posted by Glenn Kennedy View Post
    By ascending order I meant that if the 1214s were all replaced by 8888, they would appear in 3rd place (our of sequence), being preceeded by 1450 & 1560.
    Ah, yes. I assumed that the OP would want them sorting numerically, but that assumption might not be correct, you're right.

    Regards

  9. #9
    Forum Contributor
    Join Date
    08-19-2020
    Location
    Dubai
    MS-Off Ver
    Office365
    Posts
    131

    Re: Transpose and return a row values in a columns limited to one unique and one duplicate

    Many thanks all of you for your various solutions.

+ 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] formula to return unique values for duplicate values in range
    By Rerock in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 02-15-2022, 11:56 AM
  2. Transpose Data on Unique values in Multiple columns
    By Scotland-0 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 06-09-2021, 09:52 AM
  3. [SOLVED] Transpose Unique Values from tow columns to a row
    By chullan88 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 06-06-2021, 04:32 PM
  4. Replies: 1
    Last Post: 09-28-2017, 12:53 AM
  5. [SOLVED] Need to Return unique Name against duplicate values
    By samorita in forum Excel General
    Replies: 2
    Last Post: 01-10-2017, 08:56 AM
  6. Duplicate values to return unique value
    By auswtz in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 01-10-2016, 08:01 AM
  7. [SOLVED] Find count of Unique or Duplicate Values based on Concatenated values in 2 columns
    By bdicarlo1 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 12-03-2014, 12:42 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