+ Reply to Thread
Results 1 to 3 of 3

Calculation of average per row for different groups of columns

  1. #1
    Registered User
    Join Date
    03-14-2021
    Location
    Greece
    MS-Off Ver
    2016
    Posts
    2

    Calculation of average per row for different groups of columns

    I have a dataset which represents in each cell the value of stock per week (rows) for each company (columns), from 1997 to 2014. Under each company name is the stock name of the company Data sample.PNG

    For each year starting from 1997, I have created a portfolio composition including 5 groups of stocks (S, M , L , XL, XXL) per year. These groups are different from each other and from year to year

    Group.png

    My goal is to create a column to calculate for each week the average for each group . The result expected should be like this, 5 columns called S , M , L, XL , XXL and in each cell should be the average per week for the certain group stock

    resultPNG.PNG

    Is there a formula or using VBA code, that can calculate the average per week for each group?

  2. #2
    Registered User
    Join Date
    03-14-2021
    Location
    Greece
    MS-Off Ver
    2016
    Posts
    2

    Re: Calculation of average per row for different groups of columns

    Attach file
    Attached Files Attached Files

  3. #3
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,541

    Re: Calculation of average per row for different groups of columns

    Hello AngelikiSpil and Welcome to Excel Forum.
    I believe that the following does what you want:
    Please paste the following into cell C55 and then drag the fill handle down to cell C67 :
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    The formula for D55:D67 is similar:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Let us know if you have any questions.
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

+ 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] Taking the average of multiple groups of cells with ability to extend range of average
    By 2597Gar in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-29-2019, 11:07 AM
  2. Replies: 16
    Last Post: 05-22-2019, 11:48 PM
  3. [SOLVED] Average data over groups
    By dianaCatz in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-05-2019, 02:25 AM
  4. [SOLVED] Creating a dynamic calculation within groups
    By Isara-NJ in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 04-13-2017, 01:37 PM
  5. How to average different rows of different groups?
    By andaman1 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-10-2014, 10:11 AM
  6. Average of Groups
    By penfold in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-02-2010, 08:50 AM
  7. Enter average calculation in select columns
    By Buddy7 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-15-2010, 11:31 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