Encountered this when using openTSDB and I want to make sure I'm using the right function.
Difference of sum and zimsum is described here: http://opentsdb.net/docs/build/html/user_guide/query/aggregators.html
zimsum is suppose to add the data points together and fill zero if missing. I supposed 1m-zimsum and 1m-zimsum-zero should return same results. I have a single data logged in openTSDB once at 2 AM. I got a dot with 1m-zimsum but a line with 1m-zimsum-zero. Could anyone kindly explain?
I'm not super familiar with statistics and openTSDB. Please forgive me if stupid question is asked.
I was reading a question in SO and came up with the !! operator. Ive been working with R for some time and never have seen it. First, Ive search for questions about it, and couldnt find one in SO (so this may be a duplicate). Also, go back to diferent R operators post and pages, and no one says anything of it.
In the question, the !! preceded an R oject, like:
> !!object
Thanks for the help.
P.D.: If its a duplicate, please close.
I'm trying to figure out how to get a count of answers inside a cell which are comma-separated in this format: Anna, peter, Hans, Otto (here it should be 4)
Need this for an assignment and nothing seems to work and my programming are very limited so I hope someone might help me out here :/
I have tried it in excel first with this formula:
=LEN(TRIM(A1))-LEN(SUBSTITUTE(TRIM(A1),",",""))+1
..which didn't work (the brackets around the first A1 and after substitute turned red - whats that telling us anyway? My search only show me entries about negative values..)
Then I tried this formula here in google spreadsheet:
=COUNTA(SPLIT(A1; ","))
..which also didn't work (here I simply get an error).
I guess it's about the values being non numeric? Any ideas?
It is possible that you need:
=LEN(TRIM(A1))-LEN(SUBSTITUTE(TRIM(A1);",";""))+1
If your Regional Settings require it. (see Scott's comment)
This should do the trick
=LEN(A1)-LEN(SUBSTITUTE(A1,",",""))+1
It just counts the commas and adds 1
Update
I just realized that's pretty much the same as what you had - just without using TRIM which isn't necessary. Your formula should work too.
In Excel, use:
=LEN(A1)-LEN(SUBSTITUTE(A1,",","")) + 1
Unless there is a chance for A having no value, then you need to expand it farther:
=IF(LEN(A1)>0,LEN(A1)-LEN(SUBSTITUTE(A1,",","")) + 1,0)
Since you also tagged Google Spreadsheets, there use:
=COUNTA( SPLIT(A1, ",", TRUE))
Same applies for the possiblity of an empty field in Google Sheets.
Some time ago I found an ISO-standard(I think) which described boundaries to use in order to determine a word in a text based on different languages.
Is this something that I have made up in my dreams? Or can you help me find it? I've tried google but I didnt find anything.
Thanks,
BJ
Found what I was looking for. Sorry, no ISO-standard but an Unicode Standard Annex:
http://www.unicode.org/reports/tr29/tr29-25.html
I am using the following regex with a .net validator.
^100|150|200|250|300|350|400|450|500|550|600|650|700|750|800|850|900|950|1000$
The aim is to allow 1 of the values in the list.
However, whilst it works great with most, inputting '1000' produces an error.
Any ideas?
You need to limit the scope of your alternation:
^(100|150|200|250|300|350|400|450|500|550|600|650|700|750|800|850|900|950|1000)$
And of course you can optimize your regex:
^([1-9][05]0|1000)$