Mark Existing Matrix Or Array Values

Oct 28, 2006

I have this example array:

A1
B1
C1
D1
A2
B2
B3
C3
D4
C5
D5
E5

...along with this example table:

.12345
A
B
C
D
E

In my table, I want to notate every occurence of A=1,A=2,B=1, etc; by placing an "X" in the correct cell. So, the table should look like this:

.12345
AXX
BXXX
CXXX
DXXX
EX

I cannot figure out the formula. I've tried this:

=If(VLOOKUP($L6,$I$6:$J$15,2,False)=M$5,"X"," ")

....but it seems to only return the first value found, and not all occurences.

View 3 Replies


ADVERTISEMENT

How To Speed Up Large Matrix Array Formulas

Dec 31, 2013

I am trying to calculate a matrix of array formulas that is roughly 365 x 137, or about 50,000 cells being calculated from a range of roughly 12,000 x 137. There are multiple if statements within the array formula, and then those 50,000 cells are referenced to another, but smaller matrix of array formulas (25 x 137). Each of these matrix sets is for one year, and there are three years that need calculated.

Problem: When calculating the 50,000 cells it takes roughly 2.5 hours to complete all calculations. So, for 3 years it will take roughly one work day of tying up my computer to just compile data that will then require several days of calculation/manipulation.

Question(s): Is there a way to speed this up to a reasonable amount of time (I'd even take 30 minutes at this point)? Or, is Excel simply the wrong tool to be using for this amount of data? Do I need a better machine to run these calculations? I am currently using a Dell XT3 with 2.5 Ghz i5 quad core processor.

View 3 Replies View Related

Return Sum Of Array Within Matrix Based On Independent Value?

Mar 8, 2013

I'm trying to write a formula that will return the sum of multiple cells within a larger matrix, based on a number that is manually inputted into a separate table. As you can see in the top below, I have data that is grouped by both "Zone" and by individual "Stations". The Zones/Stations on the y-axis are "Start" points, while the Zones/Stations on the x-axis are "Finish" points. What I'd like to be able to do is input a Zone ID number into the bottom table (Shown as "1" below) and have the formula either return the greatest sum of "Finish" numbers. In this example, the greatest sum is 12, which is all numbers going from Station 1 and 2 in Zone 1 to Stations 1/2 in Zone 2 (3+2+4+3). In the bottom table, you'll see the "Greatest Finish" as "2", which is Zone 2. And the total from this sum is 12, as described previously. If there is a way to return either the "Total #" or "Greatest Finish" zone.

The actual matrix I am working with is much larger (150x150), and not all zones have the same amount of stations. I'm assuming this might complicate things a bit.

Finish
Zone 1
Zone 1
Zone 2

[Code]...

View 6 Replies View Related

Evaluate Multi-Dimensional Array Matrix

Feb 27, 2008

I'm trying to use VBA to do some matrix processing. I have successfully done matrix processing in the spreadsheet, but I'm looking to port the logic into VBA to more easily reuse central formulas and reduce the amount of code in the spreadsheet.

The function shown below works. I had to hack around the variable declarations to eliminate processing/compile errors but it seems to function (no pun intended).

While debugging I noticed that this function would seem to get called 4 times. I do have other modules running, although I don't think any other modules are affecting this.

After some input from shg, I updated the variable declarations, but I'm getting an "Overflow" error reported. Sometimes (not always) a divide by zero also pops up. I do have the Msgbox for errors at the end, I haven't tried removing that part to see if the error reporting vanishes. I'm not sure 'hiding' error alerts is the best thing to do anyway...

View 8 Replies View Related

Average Standard Deviation Of Array Within Matrix

Mar 7, 2008

I have tried to find information on this subject, but it seems diifficult to find exactly what I am looking for. I have provided a test example of the operation that I would like to acheive. The first example (Method 1) works well enough but would require defining more detailed functions beyond the scope of average. This would probably be ok, but more importantly, I would like to source particular arrays in this manner for other tasks beyond averages and even standard deviation and am not quite sure how this can be done. In an attempt to describe the situation, I have provided a second example (Method 2). In this example, I am trying to take the average of the jth column array to create an array of averages. I am not sure if I am incorrectly setting up the matrix, if the functions don't perform this way in the matrix, or if this is simply not possible.

Sub test()
a = 5
b = 5
Redim X(1 To a, 1 To b) As Double
'Assumes there is a matrix of values [a x b] drawn from worksheet
For j = 1 To b
For i = 1 To a
X(i, j) = Cells(i, j)
Next
Next

'----METHOD 1---------------------------------------------
'I know this way works using average as an example, but...
Redim AverageX(1 To a, 1 To b) As Double.......................

View 4 Replies View Related

Matrix To Return Risk Rating - Array Returns Opposite Result

Nov 20, 2013

I am looking up a risk matrix to return the risk rating... it is very simple, it works on one sheet, but on a different sheet (looking up different data, but same basic format) it returns exactly the opposite rating.

My formula is: =INDEX($G$6:$K$10,MATCH(I19,$G$5:$K$5,0),MATCH(J19,$F$6:$F$10,0))

Here is F4 to K10

I have data validation on I19 and J19 based on the cells below

Consequence

Priority
Very Low
Low
Medium
High
Very High

[Code] ..........

BUT... when I put Very Low and Very Low in the two cells (I19 and K19) I get Very High as the return.

View 1 Replies View Related

Mark Duplicate Values With Color Or Something

Jan 30, 2008

Excel 2007 User

Colum b:b I have values "x", "a", "b" and so on ....

But some time value x is on row 10 and row 2000

I want to mark that row on a color or something

Example:

Like a loop, So I found ...

A on cell b2

A on cell b24

View 9 Replies View Related

Userform's Listbox Values Depending On Values On Certain Matrix

Aug 16, 2008

I have problems with my userform's listboxes. I have two listboxes, and I want second listbox's values to be dependent on first listbox's values.

And even more complicated, I need second listbox's values to be dependent on values on certain matrix.

In that matrix, row headings are listbox1's values and column headings are listbox2's values. How ever there are blanc cells on that matrix aswell. So if there is a blanc cell(s) on a row which (heading) is selected at listbox1, then I don't want that column (heading) which intersects with the blanc cell to be included to my listbox2 values.

Finally I want to insert the selected values from listboxes and the value from the intersection of those listbox values (headings) on that matrix to worksheet.

I included an attachment, where you can see my point better. However, as you can see, now the listbox values are not dependent on that matrix. Otherwise it is working like I want it to work.

View 11 Replies View Related

Summing Matrix Values Based On X & Y Axis Values

Feb 24, 2009

The simplified example below is intended to calculate the sums from the data values in the upper data set and place them in the appropriate cells in the lower summary table. Example......

I would like to find a single-cell formula that will handle the multiple instances of either the X or Y headings (ex: there are two 'Yes' Rows) and still reach the appropriate summations. I would like to accomplish this without resorting to Macros or manual cell references if possible. I've acheived some limited success with array formulae so far, but find that the multiple instances of 'Yes' cause only one row to be summed before the formula finishes.

View 2 Replies View Related

Chart - Mark Y-Axis With Values From Table

Dec 18, 2008

is does anyone know if there is a way of marking the y-axis in a chart with data from a table, so rather than having a fixed segmentation width have the distances between the data points marked on the Vertical to conform to a range in a spreadsheet? I know you can do that for the x-axis. Is there any way to do that for the y-axis as well?

View 9 Replies View Related

Formula For Values In A Matrix?

Dec 28, 2011

I'm having trouble with a formula. Column A is a list of names. Row 1 is a list classes. What I need to be able to do is select a class from Row 1 in drop-down list in C14 and have it return the list of names in list starting at C17 based on the 'X'. In this example for SCIENCE it should return Tim Mark Jen. The actual file has 50+ names and 50+ classes.

Sheet1

ABCDEFGH1 MATHSCIENCEHISTORYLANGUAGEPEARTMUSIC2
JoeX XX X 3TimXX X X4MarkXX X 5SarahX X X6BrianX XX 7JenXX X 8
KathyX X X9 10 11 12 13 Class 14 SCIENCE 15 16
Required 17 Tim 18 Mark 19 Jen 20 21

View 3 Replies View Related

Conditional Sum From Matrix With Non Numerical Values

Feb 27, 2012

I am trying to conditionally sum numbers from a matrix. On the vertical axis, there will be duplicate values (text) who's rows should be summed, and on the horizontal axis I need to sum in between two numbers that will be in sequential order (such as dates). The real tough part for me is that the data field that I will be summing from has non numerical values, like dashes. Obviously, I don't want to sum the dashes, but it throws off any formulas I have tried (like sum arrays).

My hopes are to use as little memory as possible so my file size wont get too big and to not have to use macros (I do not really use them), although I am willing to try if they are basic.

In the example below, I want to sum rows for the letter "A" and in between numbers "2" and "4."

# 1 2 3 4 5
A2 6 5 4 2
B4 5 6 4 1
C-----
A4 2 1 2 1
E1 1 2 2 2

Y Variable: A
X Variable Min: 2
X Variable Max: 4

Correct Result = 20.00 = (6+5+4+2+1+2)

View 3 Replies View Related

Create Matrix From Another Table Of Values

Dec 26, 2013

I have a Table of multiple values. From this table, I need to lookup and match the corresponding value in another table, and return a "X" if the looked up values match.

For example: The table with the data in it is:

Apple
Bob

Candy
Bob

Cookie
Bob

Donut
Bob

Figs
Bob

The Table I need to create is: As follows: It will have Bob in the Top column, and the rows to the left of Bob will say, Apple, Asparagus, Candy, Cookie, Dancing, Donut, Fame, Figs, Zebra. I need to read the top table and populate with an "X" the values which have Bob.

View 9 Replies View Related

Generate Matrix Of Buttons From List Of Values

Feb 20, 2013

Maybe this problem is not too much complicated for some of you experts. I have this:

I have in sheet "Products", in column A, a lists of Products from row 2 to N. (Product 1 , Product 2, Product 15, Product 37, etc).

How to generate in sheet "Menu" a matrix of buttons with the label of each button taken from the value of each cell in column A of sheet1.

I mean, the buttons would have the label Product 1 , Product 2, Product 15, Product 37, etc. Each button associated with macro "My_Macro".

I would like that the buttons be organize as simetrical as possible (regarding number of rows and columns)

* I'm attaching sample file with input in sheet "Products" and output desired for those few products. The real list could have 100 Products.

View 6 Replies View Related

Finding Row And Columns For All TRUE Values In A Matrix

May 21, 2013

I'm using multiple data tables to run sensitivity analyses on a very large model. At the end of the analysis, I've got a matrix that tells me which scenarios are TRUE or FALSE (based on multiple criteria). I'm looking for an elegant way to extract the combinations that give TRUE.

Column1
Column2
Row1
FALSE
TRUE
Row2
TRUE
FALSE
Desired Output
True Scenarios:
R1, C2
R2, C1

View 1 Replies View Related

Lookup The Values Contained Within The Matrix To Get Distances Between Them

Oct 8, 2009

I'm updating my database of distances between different cities in our records... but the source that i have to lookup is actually a distance matrix....something like this...

From/ToMumbaiPuneDelhiKochiBanglore
Mumbai024014501800900
Pune240015501650700
Delhi14501550028002400
Kochi1800165028000500
Banglore90070024005000

Now i need to lookup the values contained within the matrix to get distances between them. I'm hoping if i can do that i dont have to actually manually sit and list down all the possible combinations of cities and distances between them but directly lookup the distances from this matrix.

View 2 Replies View Related

Return Row Number Of Complex Matrix Values?

Oct 30, 2013

In the attached sample file, one can see the setup of my data. I'm trying to reference the row number of a certain cell in a matrix with many cells of the same value. I have different Headers of each row, which should make it possible to use INDEX, MATCH or VLOOKUP. but i don't seem to be able to get it right.

Description.I need to return the "class" och each of the capability elements, i.e. If the capability in "Soups" is marked ("X"), at class 3, i need the integer "3" to be shown here.

View 12 Replies View Related

Multiselect Listbox Preselected Values From Matrix?

Apr 3, 2014

How do I preselect items in a listbox based on combobox selection and values stored in matrix.

I have attached the file with a description of what I mean

View 7 Replies View Related

Creating Adjacent Matrix From Incidence Matrix

Aug 26, 2007

I have a data chart on 200 people with overlapping membership in 20+ groups, represeted as binary (1=member, 0=notmember), for example: ...

View 9 Replies View Related

Return Inverse Matrix Of Large Matrix

Aug 22, 2008

Using VBA, I wish to work out the inverse matrix of a large matrix (100*100), but keep getting the # Num! Error. I am using the minverse function. I have defined variable as "variant", does this give me the same possiblities in terms of number size as the variable "Double"?

View 9 Replies View Related

Populate Cells In A Matrix From Goal Seek Values Based On

Aug 5, 2009

wish to write an VB macro in Excel (2003) that populates a 6 row by 10 column matrix (for a 3 D graph) by inserting values from matrix row column headers in cells in another worksheet and using goal seek to derive a value which will be pasted in the respective cell in the 6X10 matrix

Specific example: Matrix (Row Headers A2 to A7, Column Headers B1 to K1, Cell values are in B2 to K7). Please note row and column headers are numerical values since this is for a 3D graph

Macro to be written

Pick a value (numerical) from row header A3 in Sheet A and paste it in cell B6 in another sheet (Sheet B). Pick anothet value (numerical) from column header D1 in Sheet A and paste it in cell B7 in Sheet B.

Run a goal seek scenario such that cell S10 in sheet B is equal to 50 by changing cell G8 in Sheet B

Copy the value chosen/optimised by Goal Seek from cell G8 in Sheet B and paste it in Cell D3 (which is the relevant cell for the values for intersection of headers A3 and D1) in Sheet A

Macro should populate all cells in the matrix in Sheet A (matrix cells to be populated are B2 to K7) in a similar fashion

The macro should be locked in to the cells which are either being copied from or pasted into so that it still references them even if new columns or rows are inserted.

View 10 Replies View Related

Existing Values

Mar 26, 2007

I have a button setup with a macro to copy cells in a column and paste them into a row on another sheet. One of the values in the column needs to be checked in the other sheet before being added.

After the button with the macro is clicked
- If the value entered in column A (sheet 1) exists in column A (sheet 2) proceed with the rest of code.

- If the value entered in column A (sheet 1) does not exists in column A (sheet 2), Popup menu to enter details of value (just a menu with an input box and instructions), then the macro should enter the details of value (entered by user into the popup menu) in column B of sheet 3, then proceed with the rest of code.

I posted this with a different explanation before and didn't get a response so I am hoping that this is a thinned down version of my request and is more specific. Please let me know if you need more info.

View 9 Replies View Related

String Array Values To Array Of User-Defined Types

Oct 2, 2008

I have a class module with several private variables, including one that is an array of a user-defined type. I am trying to set the values of a single element of this array with "Property Let ..." from a string array:

View 4 Replies View Related

How To Add More Rows From Existing Set Of Values

Feb 26, 2014

I have a table with 2 columns and I want to create another table with the same values in these 2 columns but add a new column with values that are different. So for example, I have col A, Col B with values 256 and 14. I want to create a table that has Col A, Col B and Col C with 256 in Col A appearing 60 times, 14 in column B appearing 60 times and new Col C has values ranging from -4 to 55 for each new row. So new table now has 60 rows with same values for Columns A,B but different C value

I can drag or copy paste but when I have 200 unique records in first table, I want to create a second one with 200x60 rows and drag/copy paste is tedious.

Input

ID
SqnID
256
14

[Code]....

View 2 Replies View Related

Inserting Values In Existing Formula

Mar 17, 2009

I need to replace the values in the braces with the values in Column A. Is there an easy way to do this or am I stuck with doing each one manually? There are 92 lines in Column A.....

View 9 Replies View Related

Count Unique Text Values (number With Text And Quotation Mark) With Formula

May 14, 2012

I am trying to find a formula that will count the number of unique entries there. I have tried the solutions posted on various websites to no avail (most recently:

Code:
=SUM(IF(FREQUENCY(MATCH(A1:A10,A1:A10,0),MATCH(A1:A10,A1:A10,0))>0,1))
).

The answer should be 4,457.

Ticket Number
T20110819.0527
T20110830.0339
T20110901.0060
T20110901.0060
T20110907.0042
T20110907.0042
T20110908.0186
T20110908.0186
T20110908.0186
T20110908.0186

[code].....

View 1 Replies View Related

Copy Existing Row And Insert Values And Formula Into New Row?

Sep 1, 2013

I am trying to write a macro that should be able to copy existing row and insert values and formula into a new row just below the row. As an example below:

A
B
C
D
E

001
ADESF
500.00
1001210
EMF

The values in column C and D for the new row will be the same.

View 1 Replies View Related

Excel 2007 :: Test For Existing Values

Nov 7, 2011

I have a workbook with several tabs. the first tab is a data input sheet: subtotals from this sheet get posted to cells on the other sheets. at the top of the Data sheet is a drop down validation list that the user will select the next month from. On each of the other sheets, is a grid with calendar months down the left hand side and years across the top:

Excel 2007BCDEFGHI26Incoming111009080727Month201220112010200920082007200628
JAN1201135317522050194029FEB1392150817082130217230MAR1538164117831823246831
APR1338132717301819211632MAY1485129615762008244933JUN14991380162618652028187034
JUL15491382166020362091170335AUG16531383148619252132197236SEP15901411155620051982214937
OCT23391324159420732014247738NOV1440146718842186282139DEC15631602203721472197Incoming

I am trying to figure out a simple method to check whether there is data on any of the four other sheets in the spot corresponding to the month selected by the user on the Data tab. the format of the validation list dates are dd/mm/yyyy in cell B2 on the data tab.

View 3 Replies View Related

Checking / Unchecking Existing Values In A ListBox

Nov 5, 2012

I have a Multi Select ListBox with values from a range of cells.

I wish to automate the selection of one or more existing value(s) via VBA code so when User views the List, The check mark is visible. This will alert them to Active values.

i.e ListBox:

North
South
East
West.

If the active region is West, The check box beside West is Active, i.e contains an "X"

View 4 Replies View Related

Conditional Sum Based On Values Existing In Range

Dec 17, 2007

My problem may seem similar to "conditional sumif", but I could not solve it with that approach. The examples of sumif or sumproduct always use

E2:E25="Low"

notation, in my case I need a range on the right hand side of that comparison. I have several brands which belong to some producers. I'd like to sum the values of all brands belonging to 1 producer. The brands and their producers are listed on the same sheet. An example is attached.

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved