+ Reply to Thread
Results 1 to 11 of 11

Creating long form data in excel

  1. #1
    Registered User
    Join Date
    09-01-2017
    Location
    Yerevan, Armenia
    MS-Off Ver
    2016
    Posts
    5

    Creating long form data in excel

    Hello everyone

    I have a huge excel data that I want to transform into long or wide form so I can do regression analysis. I have been trying to convert it, but am unlucky so far.
    I would really appreciate if you would help me out with the conversion. The FY fields are the years (2010-2017).

    Please find the excel file attached.

    Thanks in advance.
    Attached Files Attached Files

  2. #2
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Creating long form data in excel

    You mean like this?
    (you didn't show example result)
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    09-01-2017
    Location
    Yerevan, Armenia
    MS-Off Ver
    2016
    Posts
    5

    Re: Creating long form data in excel

    Thank you.

    Please, see attached in excel file.
    Attached Files Attached Files

  4. #4
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Creating long form data in excel

    My dear friend, see your first attached file and create example result from data in this file
    your second example has nothing common with the first (but maybe for you only)

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.

  5. #5
    Registered User
    Join Date
    09-01-2017
    Location
    Yerevan, Armenia
    MS-Off Ver
    2016
    Posts
    5

    Re: Creating long form data in excel

    I have prepared the data as you asked. I have done it only for the first company just to give you an idea, the process is the same for other companies aswell placing the values of variables by time. I hope I made it easier for you
    Attached Files Attached Files

  6. #6
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Creating long form data in excel

    Is that what you want?

    ---
    If that takes care of your original question, & to say Thanks, please click on Add Reputtion (bottom left corner of the post of the person(s) who helped you)
    then select Thread Tools from the menu (top right corner of your thread) and mark this thread as SOLVED.
    If you did it - ignore it.
    Thank you.
    Attached Files Attached Files
    Last edited by sandy666; 09-01-2017 at 05:53 PM.

  7. #7
    Registered User
    Join Date
    09-01-2017
    Location
    Yerevan, Armenia
    MS-Off Ver
    2016
    Posts
    5

    Re: Creating long form data in excel

    Yeah thats how I wanted it. Could you tell me how you have done it, so I can do it on large samples. Thanks!

  8. #8
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Creating long form data in excel

    1. don't use merged cells
    2. use PowerQuery

    If that takes care of your original question, & to say Thanks, please click on Add Reputtion (bottom left corner of the post of the person(s) who helped you)
    then select Thread Tools from the menu (top right corner of your thread) and mark this thread as SOLVED.
    If you did it - ignore it.
    Thank you.

    here is example without any helper sheets, only source and result:
    Attached Files Attached Files
    Last edited by sandy666; 09-02-2017 at 11:41 AM.

  9. #9
    Registered User
    Join Date
    09-01-2017
    Location
    Yerevan, Armenia
    MS-Off Ver
    2016
    Posts
    5

    Re: Creating long form data in excel

    Thanks a alot! Really appreciate you helping me out.

  10. #10
    Forum Expert shukla.ankur281190's Avatar
    Join Date
    05-17-2014
    Location
    Lucknow, India
    MS-Off Ver
    Microsoft® Excel® for Microsoft 365 MSO (Version 2503 Build 16.0.18604.20000) 64-bit
    Posts
    3,992

    Re: Creating long form data in excel

    Ok try with some formulas

    A2
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    B2
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    C2
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    All drag down.

    D2=INDEX(Before!$C$3:$BF$10,MATCH($B2,Before!$B$3:$B$10,0),MATCH(D$1&$C2,INDEX(Before!$C$1:$BF$1&Before!$C$2:$BF$2,),0))

    Copy across the all the cells till J65

    Check the attached file.
    Attached Files Attached Files
    If I helped, Don't forget to add reputation (click on the little star ★ at bottom of this post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)

  11. #11
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Creating long form data in excel

    In the post #8 I attached wrong file.
    Now should be ok.
    Sorry for inconvenience

+ 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] help creating a user form using data from an excel sheet
    By ndresjavier in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-11-2016, 10:49 PM
  2. [SOLVED] =IF and =SUMIF formulas creating long long long data processing times.
    By comp in forum Excel Programming / VBA / Macros
    Replies: 32
    Last Post: 03-26-2014, 02:59 PM
  3. Creating Excel VBA Form wanting to edit current data
    By snrh1228 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-09-2012, 01:02 PM
  4. Help with creating Form in Excel that pulls data from table
    By docdiggler2 in forum Excel General
    Replies: 0
    Last Post: 11-05-2012, 12:41 PM
  5. Creating a data input form excel 2007
    By neonindian89 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-14-2011, 03:58 AM
  6. Creating a Data Entry Form on Excel
    By pinkgold in forum Excel General
    Replies: 4
    Last Post: 02-06-2009, 02:20 PM
  7. Creating a Custom Data Entry Form to Update Multiple Excel Records at Once
    By Scotty81 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 01-19-2009, 04:30 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