Need help with formula in numbers.
BRIEF INTRO.
I have a log of assets that I trade on an exchange. I fill the log every time I buy/sell.
My table (see the picture attached) consists of:
Column A = DATE. (a particular point or period of time by the Gregorian calendar)
Column B = type of transaction. (whether the transaction i make is buy or sell) (!)
Column C = trading pair. (the pair that the assets is traded with e.x. USD or BTC or ETH)
Column D = amount of an asset that I bought. (duh..)(!)
Column bla bla bla... not relevant in this case.
P.S. Column with (!) are the ones that are relevant to the problem.
WHAT I NEED.
I want to use a formula that will calculate my total holdings of a particular asset (in this case cryptocurrency "NEO"). It should determine whether am I buying (therefore it should add the amount of "new" asset I bought) or selling (therefore it should subtract the amount of asset I sold).
I have tried to use IF function, did not work.
Any ideas on which function to use and how to make it work???
See the picture attached for further explanation. If not clear ask.
BRIEF INTRO.
I have a log of assets that I trade on an exchange. I fill the log every time I buy/sell.
My table (see the picture attached) consists of:
Column A = DATE. (a particular point or period of time by the Gregorian calendar)
Column B = type of transaction. (whether the transaction i make is buy or sell) (!)
Column C = trading pair. (the pair that the assets is traded with e.x. USD or BTC or ETH)
Column D = amount of an asset that I bought. (duh..)(!)
Column bla bla bla... not relevant in this case.
P.S. Column with (!) are the ones that are relevant to the problem.
WHAT I NEED.
I want to use a formula that will calculate my total holdings of a particular asset (in this case cryptocurrency "NEO"). It should determine whether am I buying (therefore it should add the amount of "new" asset I bought) or selling (therefore it should subtract the amount of asset I sold).
I have tried to use IF function, did not work.
Any ideas on which function to use and how to make it work???
See the picture attached for further explanation. If not clear ask.
Last edited: