I am trying to create a cell that can track win streak/losing streaks for my sheet
Basically
Overall Stats B9 Cell: gathers data of Trades sheet Z column of positive and negative R(return) and if there are multiple positive Rs, it would count the winning streak. If you could also create a losing streak that would help thank you.
https://docs.google.com/spreadsheets/d/1OQg3R0796dRjlHZb4wZzaTM2QgjIRuICOroq8e5xXi8/edit?usp=sharing
try:
=COUNTA(IFNA(FILTER(Z:Z, Z:Z*1>0)))
and:
=COUNTA(IFNA(FILTER(Z:Z, Z:Z*1<0)))
Related
So I manufacture products and the challenge is I need to work out in a Google Sheets spreadsheet how many of each of my recipes (flower bouquets in this case) I can make with the current stock on hand.
I have a dataset which shows my stock qty (number of each flower) in column B, then I have my products across the top of the page in a row. Product 1 is shown in column C, Product 2 in D etc....
Here is the example.
Divide two arrays and return lowest number
As I have hundreds of products and also hundreds of different component parts I need to work out what formula can essentially divide these two arrays and return to me the MIN or lowest number, this is essentially the number of bouquets I can make.
Thanks in advance
I have tried experimenting with SUMPRODUCT as I wondered if you can use this for division as well as multiplication, but I cannot seem to fathom this
Use the following formula in C11:
= ROUNDDOWN(MIN(ARRAYFORMULA(IFERROR( $B2:$B9/C2:C9 ))))
You can then drag the formula to D11.
Alternatively you can use the new bycol function to calculate the complete array:
= BYCOL(ARRAYFORMULA(IFERROR( B2:B9/C2:D9 )), LAMBDA(x, ROUNDDOWN(MIN(x))))
If you could help me finding a formula that would solve my problem that I've been searching for a solution a few days now
So in my "feuil 1" I have what I'm searching for according to multiple values
-the aircraft number
-data 1
-cell number
-exit date (the value that I'm looking for)
And in another sheet "LH Synthèse" (the database) I have the aircraft number and data 1 in the same row and the cell number that will give me the exit date according to a specific aircraft and data 1 is the column value
What I want to do with this spreadsheet is to have a formula that is going to give me the exit date (present in the sheet "LH Synthèse") according to the values that are in the column A, B, C in the sheet "feuil 1"
The link of the spreadsheet in case my description isn't clear enough
https://docs.google.com/spreadsheets/d/1W4jVDT4wiui5h7i9Sx9rptyLnExhQvn9ICEDTFyat0E/edit?usp=drivesdk
Thanks for your help in advance
What I tried:
Index and match function
Filter function
Vlookup
use:
=INDEX(IFNA(VLOOKUP(A2&B2&C2; SPLIT(FLATTEN('LH Synthèse '!A3:A100&'LH Synthèse '!B3:B100&'LH Synthèse '!C2:K2&"×"&'LH Synthèse '!C3:K100); "×"); 2; 0)))
I am trying to create a savings spreadsheet where people save X amount of days in a week after they have reached X amount in income.
Can any Google Sheet experts help me achieve the following:
When the "amount" >= "min amount" (C1) then repeat the number of No's and Yes's according to the pattern (number of consecutive days) in B2 and B3
Example image:
example google sheet image
Example Google Sheet:
https://docs.google.com/spreadsheets/d/1n4Jg_uZUHBKi36S7HnkWWqqBTSTo3nKY9QgWP7wK9_o/edit?usp=sharing
Here's a possible solution.
={"SAVE:";ArrayFormula(if(A11:A52<C1,"NO",
{if(sequence(countif(A11:A52,"<"&C1)),);
array_constrain(flatten(split(concatenate(transpose(
if(sequence(1,countif(A11:A52,">="&C1)),
rept({"YES";"NO"}&"❄️",C2:C3)))),"❄️")),countif(A11:A52,">="&C1),1)}))}
There is a financial stock portfolio tracking spreadsheet available here.
What I found was that this spreadsheet is not counting Dividend transactions towards the Units count on the Stock Summary page, which skews the Summary page, undervaluing your portfolio.
I think to make the spreadsheet more accurate, I need to adjust the Cumulative Units (column J) cell formulas on the Transactions sheet (link) to also count units received as Dividends. The cells in column J have formula:
(Cell J2):
=if(B2="Buy",I2+D2,if(B2="Sell",I2-D2,if(B2="Div",I2,if(B2="Split",I2*G2,if(B2="CapReduct",I2,0)))))
I've tested this formula, and the cumulative units count does not update when the transaction is a Div.
How do I adjust the 2nd formula above to count both Buy & Div transactions?
Thanks in advance. Help appreciated.
The simplest way would be for you to add a new column (You can hide it) and test
if B2 is Buy or Div
=OR(B2="Buy",B2="Div")
This function will return TRUE or FALSE.
Now you amend your original formula to read this new column (rather than B2, let's say you are doing this calculation on K2) for TRUE, rather than Buy.
Try this then:
=IF(K2=TRUE,I2+D2,IF(B2="Sell",I2-D2,IF(B2="Div",I2,IF(B2="Split",I2*G2,IF(B2="CapReduct",I2,0)))))
Sorry in simple steps, in case it's confusing:
If you can free-up row K2 and add this formula:
=OR(B2="Buy",B2="Div")
Change your original formula (that you
posted) to this:
=IF(K2=TRUE,I2+D2,IF(B2="Sell",I2-D2,IF(B2="Div",I2,IF(B2="Split",I2*G2,IF(B2="CapReduct",I2,0)))))
I'm trying to calculate weekly sums in a single column, but I'm having trouble writing the formula. I'm found the the weeknum for every date in the year, but I can't find a way to sum up values if they have the same weeknum.
Link to my spreadsheet: https://docs.google.com/spreadsheets/d/1WIeBpRndO9ZBlkCcWQuNO1X4e9I6bGeQiYDTZqhaOeA/edit#gid=0
I'd like column "D" to automatically calculate the weekly sum using an array formula -- is there a way to do this?
This thread introduces the problem: Calculate weekly and monthly total in spreadsheet.
Chang sum() to sumif()
=ARRAYFORMULA(IF(ROW(A:A)=1,"Weekly Sum", IF(WEEKDAY(A:A)=7, sumif(C:C,C:C,B:B),)))
You have: A2:A with dates and B2:B with values. So:
F2=arrayformula(if(isblank(A2:A),,weeknum(A2:A)))
G2=if(F2<>F1,sum(iferror(filter(B$2:B,F$2:F=F2),0)),0)
And then copy G2 through G3:G.