У меня есть файл с более чем 30 000 строк, мне нужно посчитать количество вхождений в день за каждые полчаса (но должно быть 3: 05,3: 35, 4:05 ...), и у меня есть один год данных.
в столбце A есть даты, в столбце B - время, а в столбце C - значения, которые я добавил, чтобы проверить, сколько у меня встречается каждые полчаса.
Column A Column B Column C
1/12/19 3:37 PM 12:05 AM
1/11/19 2:27 PM 12:35 AM
1/11/19 5:37 PM 1:05 AM
1/10/19 8:32 PM 1:35 AM
это то, что у меня есть для моей формулы, которая работает, если я указал диапазон, но мне нужно, чтобы он просто начинал подсчет каждый день, поскольку у меня сотни строк в день.
=IF(AND(P3>=$AD$3,P3<=$AD$4),COUNTIFS($P$3:$P$17,">="&$AD$3,$P$3:$P$17,"<="&AD$4),IF(AND(P3>=$AD$4,P3<=$AD$5),COUNTIFS($P$3:$P$17,">="&$AD$4,$P$3:$P$17,"<="&$AD$5),IF(AND(P3>=$AD$5,P3<=$AD$6),COUNTIFS($P$3:$P$17,">="&$AD$5,$P$3:$P$17,"<="&$AD$6),IF(AND(P3>=$AD$6,P3<=$AD$7),COUNTIFS($P$3:$P$17,">="&$AD$6,$P$3:$P$17,"<="&$AD$7),IF(AND(P3>=$AD$7,P3<=$AD$8),COUNTIFS($P$3:$P$17,">="&$AD$7,$P$3:$P$17,"<="&$AD$8),IF(AND(P3>=$AD$8,P3<=$AD$9),COUNTIFS($P$3:$P$17,">="&$AD$8,$P$3:$P$17,"<="&$AD$9),IF(AND(P3>=$AD$9,P3<=$AD$10),COUNTIFS($P$3:$P$17,">="&$AD$9,$P$3:$P$17,"<="&$AD$10),IF(AND(P3>=$AD$10,P3<=$AD$11),COUNTIFS($P$3:$P$17,">="&$AD$10,$P$3:$P$17,"<="&$AD$11),IF(AND(P3>=$AD$11,P3<=$AD$12),COUNTIFS($P$3:$P$17,">="&$AD$11,$P$3:$P$17,"<="&$AD$12),IF(AND(P3>=$AD$12,P3<=$AD$13),COUNTIFS($P$3:$P$17,">="&$AD$12,$P$3:$P$17,"<="&$AD$13),IF(AND(P3>=$AD$13,P3<=$AD$14),COUNTIFS($P$3:$P$17,">="&$AD$13,$P$3:$P$17,"<="&$AD$14),IF(AND(P3>=$AD$14,P3<=$AD$15),COUNTIFS($P$3:$P$17,">="&$AD$14,$P$3:$P$17,"<="&$AD$15),IF(AND(P3>=$AD$15,P3<=$AD$16),COUNTIFS($P$3:$P$17,">="&$AD$15,$P$3:$P$17,"<="&$AD$16),IF(AND(P3>=$AD$16,P3<=$AD$17),COUNTIFS($P$3:$P$17,">="&$AD$16,$P$3:$P$17,"<="&$AD$17),IF(AND(P3>=$AD$17,P3<=$AD$18),COUNTIFS($P$3:$P$17,">="&$AD$17,$P$3:$P$17,"<="&$AD$18),IF(AND(P3>=$AD$18,P3<=$AD$19),COUNTIFS($P$3:$P$17,">="&$AD$18,$P$3:$P$17,"<="&$AD$19),IF(AND(P3>=$AD$19,P3<=$AD$20),COUNTIFS($P$3:$P$17,">="&$AD$19,$P$3:$P$17,"<="&$AD$20),IF(AND(P3>=$AD$20,P3<=$AD$21),COUNTIFS($P$3:$P$17,">="&$AD$20,$P$3:$P$17,"<="&$AD$21),IF(AND(P3>=$AD$21,P3<=$AD$22),COUNTIFS($P$3:$P$17,">="&$AD$21,$P$3:$P$17,"<="&$AD$22),IF(AND(P3>=$AD$22,P3<=$AD$23),COUNTIFS($P$3:$P$17,">="&$AD$22,$P$3:$P$17,"<="&$AD$23),IF(AND(P3>=$AD$23,P3<=$AD$24),COUNTIFS($P$3:$P$17,">="&$AD$23,$P$3:$P$17,"<="&$AD$24),IF(AND(P3>=$AD$24,P3<=$AD$25),COUNTIFS($P$3:$P$17,">="&$AD$24,$P$3:$P$17,"<="&$AD$25),IF(AND(P3>=$AD$25,P3<=$AD$26),COUNTIFS($P$3:$P$17,">="&$AD$25,$P$3:$P$17,"<="&$AD$26),IF(AND(P3>=$AD$26,P3<=$AD$27),COUNTIFS($P$3:$P$17,">="&$AD$26,$P$3:$P$17,"<="&$AD$27),IF(AND(P3>=$AD$27,P3<=$AD$28),COUNTIFS($P$3:$P$17,">="&$AD$27,$P$3:$P$17,"<="&$AD$28),IF(AND(P3>=$AD$28,P3<=$AD$29),COUNTIFS($P$3:$P$17,">="&$AD$28,$P$3:$P$17,"<="&$AD$29),IF(AND(P3>=$AD$29,P3<=$AD$30),COUNTIFS($P$3:$P$17,">="&$AD$29,$P$3:$P$17,"<="&$AD$30),IF(AND(P3>=$AD$30,P3<=$AD$31),COUNTIFS($P$3:$P$17,">="&$AD$30,$P$3:$P$17,"<="&$AD$31),IF(AND(P3>=$AD$31,P3<=$AD$32),COUNTIFS($P$3:$P$17,">="&$AD$31,$P$3:$P$17,"<="&$AD$32),IF(AND(P3>=$AD$32,P3<=$AD$33),COUNTIFS($P$3:$P$17,">="&$AD$32,$P$3:$P$17,"<="&$AD$33),IF(AND(P3>=$AD$33,P3<=$AD$34),COUNTIFS($P$3:$P$17,">="&$AD$33,$P$3:$P$17,"<="&$AD$34),IF(AND(P3>=$AD$34,P3<=$AD$35),COUNTIFS($P$3:$P$17,">="&$AD$34,$P$3:$P$17,"<="&$AD$35),IF(AND(P3>=$AD$35,P3<=$AD$36),COUNTIFS($P$3:$P$17,">="&$AD$35,$P$3:$P$17,"<="&$AD$36),IF(AND(P3>=$AD$36,P3<=$AD$37),COUNTIFS($P$3:$P$17,">="&$AD$36,$P$3:$P$17,"<="&$AD$37),IF(AND(P3>=$AD$37,P3<=$AD$38),COUNTIFS($P$3:$P$17,">="&$AD$37,$P$3:$P$17,"<="&$AD$38),IF(AND(P3>=$AD$38,P3<=$AD$39),COUNTIFS($P$3:$P$17,">="&$AD$38,$P$3:$P$17,"<="&$AD$39),IF(AND(P3>=$AD$39,P3<=$AD$40),COUNTIFS($P$3:$P$17,">="&$AD$39,$P$3:$P$17,"<="&$AD$40),IF(AND(P3>=$AD$40,P3<=$AD$41),COUNTIFS($P$3:$P$17,">="&$AD$40,$P$3:$P$17,"<="&$AD$41),IF(AND(P3>=$AD$41,P3<=$AD$42),COUNTIFS($P$3:$P$17,">="&$AD$41,$P$3:$P$17,"<="&$AD$42),IF(AND(P3>=$AD$42,P3<=$AD$43),COUNTIFS($P$3:$P$17,">="&$AD$42,$P$3:$P$17,"<="&$AD$43),IF(AND(P3>=$AD$43,P3<=$AD$44),COUNTIFS($P$3:$P$17,">="&$AD$43,$P$3:$P$17,"<="&$AD$44),IF(AND(P3>=$AD$44,P3<=$AD$45),COUNTIFS($P$3:$P$17,">="&$AD$44,$P$3:$P$17,"<="&$AD$45),IF(AND(P3>=$AD$45,P3<=$AD$46),COUNTIFS($P$3:$P$17,">="&$AD$45,$P$3:$P$17,"<="&$AD$46),IF(AND(P3>=$AD$46,P3<=$AD$47),COUNTIFS($P$3:$P$17,">="&$AD$46,$P$3:$P$17,"<="&$AD$47),IF(AND(P3>=$AD$47,P3<=$AD$48),COUNTIFS($P$3:$P$17,">="&$AD$47,$P$3:$P$17,"<="&$AD$48),IF(AND(P3>=$AD$48,P3<=$AD$49),COUNTIFS($P$3:$P$17,">="&$AD$48,$P$3:$P$17,"<="&$AD$49),IF(AND(P3>=$AD$49,P3<=$AD$50),COUNTIFS($P$3:$P$17,">="&$AD$49,$P$3:$P$17,"<="&$AD$50),"NO IN RANGE"))))))))))))))))))))))))))))))))))))))))))))))