68616691

Date: 2021-08-02 06:27:30
Score: 6
Natty:
Report link

منظورت همون حالتیه که صفحه سمت چپش فاصله ی خیلی زیاد داره سفید؟

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Captain . Andreas

68611807

Date: 2021-08-01 16:26:14
Score: 7
Natty:
Report link

🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): 🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕🍕
  • Low entropy (1):
  • Low reputation (1):
Posted by: Rita Arej

68606934

Date: 2021-08-01 02:53:27
Score: 6
Natty:
Report link

Як найчастіше його перезавонтажувати,він мае можливість перенопоуги.

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Lena

68603888

Date: 2021-07-31 17:28:43
Score: 6
Natty: 5
Report link

Привет у меня ОС win7x64. У меня не получается запустить последний релиз. Старые не пробовал. Ругается что нужен питон 3.9, но эта версия не поддерживается Win7(((

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Pinokiop240

68580555

Date: 2021-07-29 18:41:24
Score: 8.5
Natty: 7.5
Report link

Та же проблема, как ты откатил версию?

Reasons:
  • Low length (2):
  • No code block (0.5):
  • Ends in question mark (2):
  • No latin characters (3):
  • Low reputation (1):
Posted by: whois leshalight

68555889

Date: 2021-07-28 08:14:00
Score: 6
Natty: 4.5
Report link

А как вам удалось получить файлы EUSignCP.py и EUSignCP.pyd? На сайте разработчика скачать их нет возможности. В дистрибутивах "Користувач ЦСК-1" они тоже отсутствуют. Написал пару запросов на IIT - они игнорят. Я уже пробовал работать с их библиотекой euscp.so из Ruby через FFI, но там проблемы с сопоставлением строковых типов и решить мне их не удалось. Вот решил попробовать через Python, тем более, что у разработчика есть готовый интерфейс, но немогу найти эти модули. Может поделитесь инфой где их можно раздобыть?

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Ends in question mark (2):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Игорь Василишин

68546091

Date: 2021-07-27 14:51:32
Score: 2
Natty:
Report link

Is this what you need?

data %>%
  mutate(result = case_when(grepl('15(;\\d+;){,3}17', seq) & grepl('16(;\\d+;){,1}18', seq) ~ 'Both', 
                            grepl('15(;\\d+;){,1}17', seq) ~ 'First', 
                            grepl('16(;\\d+;){,3}18', seq) ~ 'Second', 
                            TRUE ~ 'Neither'))
    seq                                                                   result
1  [0;20;1;2;3;4;5;6;7;22;8;9;10;11;12;13;14;23;17;24;18;25;15;26;16;19] Neither
2  [0;21;16;27;15;28;8;9;10;11;12;13;14;29;1;2;3;4;5;6;7;30;18;31;17;19] Neither
3  [0;20;15;22;16;23;18;24;17;25;1;2;3;4;5;6;7;26;8;9;10;11;12;13;14;19]  Second
4  [0;20;8;9;10;11;12;13;14;22;1;2;3;4;5;6;7;23;15;24;16;25;17;26;18;19] Neither
5  [0;21;18;27;17;28;15;29;16;30;8;9;10;11;12;13;14;31;1;2;3;4;5;6;7;19] Neither
6  [0;20;1;2;3;4;5;6;7;22;8;9;10;11;12;13;14;23;15;24;16;25;17;26;18;19] Neither
7  [0;21;1;2;3;4;5;6;7;27;8;9;10;11;12;13;14;28;17;29;18;30;16;31;15;19] Neither
8  [0;20;8;9;10;11;12;13;14;22;1;2;3;4;5;6;7;23;16;24;15;25;18;26;17;19] Neither
9  [0;21;17;27;18;28;16;29;15;30;8;9;10;11;12;13;14;31;1;2;3;4;5;6;7;19] Neither
10 [0;20;15;22;16;23;18;24;17;25;8;9;10;11;12;13;14;26;1;2;3;4;5;6;7;19]  Second
11 [0;21;18;27;17;28;16;29;15;30;1;2;3;4;5;6;7;31;8;9;10;11;12;13;14;19] Neither
12 [0;20;1;2;3;4;5;6;7;22;8;9;10;11;12;13;14;23;18;24;17;25;16;26;15;19] Neither
13 [0;21;15;27;16;28;1;2;3;4;5;6;7;29;8;9;10;11;12;13;14;30;18;31;17;19] Neither
14 [0;21;1;2;3;4;5;6;7;27;8;9;10;11;12;13;14;28;15;29;16;30;18;31;17;19]  Second
15 [0;20;16;22;15;23;17;24;18;25;1;2;3;4;5;6;7;26;8;9;10;11;12;13;14;19]   First
16 [0;20;18;22;17;23;15;24;16;25;8;9;10;11;12;13;14;26;1;2;3;4;5;6;7;19] Neither
17 [0;21;15;27;16;28;8;9;10;11;12;13;14;29;1;2;3;4;5;6;7;30;18;31;17;19] Neither
18 [0;21;15;27;16;28;1;2;3;4;5;6;7;29;8;9;10;11;12;13;14;30;17;31;18;19] Neither
19 [0;21;18;27;17;28;15;29;16;30;1;2;3;4;5;6;7;31;8;9;10;11;12;13;14;19] Neither
20 [0;20;16;22;15;23;17;24;18;25;8;9;10;11;12;13;14;26;1;2;3;4;5;6;7;19]   First
21 [0;21;8;9;10;11;12;13;14;27;1;2;3;4;5;6;7;28;17;29;18;30;16;31;15;19] Neither
22 [0;20;16;22;15;23;18;24;17;25;1;2;3;4;5;6;7;26;8;9;10;11;12;13;14;19] Neither
23 [0;21;8;9;10;11;12;13;14;27;1;2;3;4;5;6;7;28;18;29;17;30;16;31;15;19] Neither
24 [0;20;15;22;16;23;1;2;3;4;5;6;7;24;8;9;10;11;12;13;14;25;18;26;17;19] Neither
25 [0;21;16;27;15;28;18;29;17;30;8;9;10;11;12;13;14;31;1;2;3;4;5;6;7;19] Neither
26 [0;20;15;22;16;23;17;24;18;25;1;2;3;4;5;6;7;26;8;9;10;11;12;13;14;19] Neither

Data:

data <- data.frame(seq = c("[0;20;1;2;3;4;5;6;7;22;8;9;10;11;12;13;14;23;17;24;18;25;15;26;16;19]", 
                        "[0;21;16;27;15;28;8;9;10;11;12;13;14;29;1;2;3;4;5;6;7;30;18;31;17;19]", 
                        "[0;20;15;22;16;23;18;24;17;25;1;2;3;4;5;6;7;26;8;9;10;11;12;13;14;19]", 
                        "[0;20;8;9;10;11;12;13;14;22;1;2;3;4;5;6;7;23;15;24;16;25;17;26;18;19]", 
                        "[0;21;18;27;17;28;15;29;16;30;8;9;10;11;12;13;14;31;1;2;3;4;5;6;7;19]", 
                        "[0;20;1;2;3;4;5;6;7;22;8;9;10;11;12;13;14;23;15;24;16;25;17;26;18;19]", 
                        "[0;21;1;2;3;4;5;6;7;27;8;9;10;11;12;13;14;28;17;29;18;30;16;31;15;19]", 
                        "[0;20;8;9;10;11;12;13;14;22;1;2;3;4;5;6;7;23;16;24;15;25;18;26;17;19]", 
                        "[0;21;17;27;18;28;16;29;15;30;8;9;10;11;12;13;14;31;1;2;3;4;5;6;7;19]", 
                        "[0;20;15;22;16;23;18;24;17;25;8;9;10;11;12;13;14;26;1;2;3;4;5;6;7;19]", 
                        "[0;21;18;27;17;28;16;29;15;30;1;2;3;4;5;6;7;31;8;9;10;11;12;13;14;19]", 
                        "[0;20;1;2;3;4;5;6;7;22;8;9;10;11;12;13;14;23;18;24;17;25;16;26;15;19]", 
                        "[0;21;15;27;16;28;1;2;3;4;5;6;7;29;8;9;10;11;12;13;14;30;18;31;17;19]", 
                        "[0;21;1;2;3;4;5;6;7;27;8;9;10;11;12;13;14;28;15;29;16;30;18;31;17;19]", 
                        "[0;20;16;22;15;23;17;24;18;25;1;2;3;4;5;6;7;26;8;9;10;11;12;13;14;19]", 
                        "[0;20;18;22;17;23;15;24;16;25;8;9;10;11;12;13;14;26;1;2;3;4;5;6;7;19]", 
                        "[0;21;15;27;16;28;8;9;10;11;12;13;14;29;1;2;3;4;5;6;7;30;18;31;17;19]", 
                        "[0;21;15;27;16;28;1;2;3;4;5;6;7;29;8;9;10;11;12;13;14;30;17;31;18;19]", 
                        "[0;21;18;27;17;28;15;29;16;30;1;2;3;4;5;6;7;31;8;9;10;11;12;13;14;19]", 
                        "[0;20;16;22;15;23;17;24;18;25;8;9;10;11;12;13;14;26;1;2;3;4;5;6;7;19]", 
                        "[0;21;8;9;10;11;12;13;14;27;1;2;3;4;5;6;7;28;17;29;18;30;16;31;15;19]", 
                        "[0;20;16;22;15;23;18;24;17;25;1;2;3;4;5;6;7;26;8;9;10;11;12;13;14;19]", 
                        "[0;21;8;9;10;11;12;13;14;27;1;2;3;4;5;6;7;28;18;29;17;30;16;31;15;19]", 
                        "[0;20;15;22;16;23;1;2;3;4;5;6;7;24;8;9;10;11;12;13;14;25;18;26;17;19]", 
                        "[0;21;16;27;15;28;18;29;17;30;8;9;10;11;12;13;14;31;1;2;3;4;5;6;7;19]", 
                        "[0;20;15;22;16;23;17;24;18;25;1;2;3;4;5;6;7;26;8;9;10;11;12;13;14;19]"
))
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • Ends in question mark (2):
  • Starts with a question (0.5): Is this
  • No latin characters (3):
  • High reputation (-2):
Posted by: Chris Ruehlemann

68527764

Date: 2021-07-26 10:56:22
Score: 1
Natty:
Report link

let records = [1612271438035, 1612271489789, 1612271498250, 1612271498756, 1612271499731, 1612271507831, 1612271508337, 1612271509048, 1612271511891, 1612271511895, 1612271512084, 1612271519936, 1612271520438, 1612271521713, 1612271525260, 1612271525264, 1612271527431, 1612271544137, 1612271544640, 1612271546389, 1612271551144, 1612271551646, 1612271553157, 1612271553163, 1612271557885, 1612271558028, 1612271558032, 1612271559399, 1612271559402, 1612271564461, 1612271564566, 1612271564570, 1612271564572, 1612271564577, 1612271567860, 1612271567863, 1612271568180, 1612271573603, 1612271573607, 1612271601243, 1612271601355, 1612271603883, 1612271604061, 1612271608817, 1612271608930, 1612271612965, 1612271613999]

let results = records.slice(1).map((e,i) => records[i+1] - records[i])

console.log(results)

Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Alan Omar

68526196

Date: 2021-07-26 08:53:02
Score: 3
Natty:
Report link

I did advise that StatguyUser suggested, but it not works.

My error message is like this

['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31', '32', '33', '34', '35', '36', '37', '38', '39', '40', '41', '42', '43', '44', '45', '46', '47', '48', '49', '50', '51', '52', '53', '54', '55', '56', '57', '58', '59', '60', '61', '62', '63', '64', '65', '66', '67', '68', '69', '70', '71', '72', '73', '74', '75', '76', '77', '78', '79', '80', '81', '82', '83', '84', '85', '86', '87', '88', '89', '90', '91', '92', '93', '94', '95', '96', '97', '98', '99', '100', '101', '102', '103', '104', '105', '106', '107', '108', '109', '110', '111', '112', '113', '114', '115', '116', '117', '118', '119', '120', '121', '122', '123', '124', '125', '126', '127', '128', '129', '130', '131', '132', '133', '134', '135', '136', '137', '138', '139', '140', '141', '142', '143', '144', '145', '146', '147', '148', '149', '150', '151', '152', '153', '154', '155', '156', '157', '158', '159', '160', '161', '162', '163', '164', '165', '166', '167', '168', '169', '170', '171', '172', '173', '174', '175', '176', '177', '178', '179', '180', '181', '182', '183', '184', '185', '186', '187', '188', '189', '190', '191', '192', '193', '194', '195', '196', '197', '198', '199', '200', '201', '202', '203', '204', '205', '206', '207', '208', '209', '210', '211', '212', '213', '214', '215', '216', '217', '218', '219', '220', '221', '222', '223', '224', '225', '226', '227', '228', '229', '230', '231', '232', '233', '234', '235', '236', '237', '238', '239', '240', '241', '242', '243', '244', '245', '246', '247', '248', '249', '250', '251', '252', '253', '254', '255', '256', '257', '258', '259', '260', '261', '262', '263', '264', '265', '266', '267', '268', '269', '270', '271', '272', '273', '274', '275', '276', '277', '278', '279', '280', '281', '282', '283', '284', '285', '286', '287', '288', '289', '290', '291', '292', '293', '294', '295', '296', '297', '298', '299', '300', '301', '302', '303', '304', '305', '306', '307', '308', '309', '310', '311', '312', '313', '314', '315', '316', '317', '318', '319', '320', '321', '322', '323', '324', '325', '326', '327', '328', '329', '330', '331', '332', '333', '334', '335', '336', '337', '338', '339', '340', '341', '342', '343', '344', '345', '346', '347', '348', '349', '350', '351', '352', '353', '354', '355', '356', '357', '358', '359', '360', '361', '362', '363', '364', '365', '366', '367', '368', '369', '370', '371', '372', '373', '374', '375', '376', '377', '378', '379', '380', '381', '382', '383', '384', '385', '386', '387', '388', '389', '390', '391', '392', '393', '394', '395', '396', '397', '398', '399', '400', '401', '402', '403', '404', '405', '406', '407', '408', '409', '410', '411', '412', '413', '414', '415', '416', '417', '418', '419', '420', '421', '422', '423', '424', '425', '426', '427', '428', '429', '430', '431', '432', '433', '434', '435', '436', '437', '438', '439', '440', '441', '442', '443', '444', '445', '446', '447', '448', '449', '450', '451', '452', '453', '454', '455', '456', '457', '458', '459', '460', '461', '462', '463', '464', '465', '466', '467', '468', '469', '470', '471', '472', '473', '474', '475', '476', '477', '478', '479', '480', '481', '482', '483', '484', '485', '486', '487', '488', '489', '490', '491', '492', '493', '494', '495', '496', '497', '498', '499', '500', '501', '502', '503', '504', '505', '506', '507', '508', '509', '510', '511', '512', '513', '514', '515', '516', '517', '518', '519', '520', '521', '522', '523', '524', '525', '526', '527', '528', '529', '530', '531', '532', '533', '534', '535', '536', '537', '538', '539', '540', '541', '542', '543', '544', '545', '546', '547', '548', '549', '550', '551', '552', '553', '554', '555', '556', '557', '558', '559', '560', '561', '562', '563', '564', '565', '566', '567', '568', '569', '570', '571', '572', '573', '574', '575', '576', '577', '578', '579', '580', '581', '582', '583', '584', '585', '586', '587', '588', '589', '590', '591', '592', '593', '594', '595', '596', '597', '598', '599', '600', '601', '602', '603', '604', '605', '606', '607', '608', '609', '610', '611', '612', '613', '614', '615', '616', '617', '618', '619', '620', '621', '622', '623', '624', '625', '626', '627', '628', '629', '630', '631', '632', '633', '634', '635', '636', '637', '638', '639', '640', '641', '642', '643', '644', '645', '646', '647', '648', '649', '650', '651', '652', '653', '654', '655', '656', '657', '658', '659', '660', '661', '662', '663', '664', '665', '666', '667', '668', '669', '670', '671', '672', '673', '674', '675', '676', '677', '678', '679', '680', '681', '682', '683', '684', '685', '686', '687', '688', '689', '690', '691', '692', '693', '694', '695', '696', '697', '698', '699', '700', '701', '702', '703', '704', '705', '706', '707', '708', '709', '710', '711', '712', '713', '714', '715', '716', '717', '718', '719', '720', '721', '722', '723', '724', '725', '726', '727', '728', '729', '730', '731', '732', '733', '734', '735', '736', '737', '738', '739', '740', '741', '742', '743', '744', '745', '746', '747', '748', '749', '750', '751', '752', '753', '754', '755', '756', '757', '758', '759', '760', '761', '762', '763', '764', '765', '766', '767', '768', '769', '770', '771', '772', '773', '774', '775', '776', '777', '778', '779', '780', '781', '782', '783', '784', '785', '786', '787', '788', '789', '790', '791', '792', '793', '794', '795', '796', '797', '798', '799', '800', '801', '802', '803', '804', '805', '806', '807', '808', '809', '810', '811', '812', '813', '814', '815', '816', '817', '818', '819', '820', '821', '822', '823', '824', '825', '826', '827', '828', '829', '830', '831', '832', '833', '834', '835', '836', '837', '838', '839', '840', '841', '842', '843', '844', '845', '846', '847', '848', '849', '850', '851', '852', '853', '854', '855', '856', '857', '858', '859', '860', '861', '862', '863', '864', '865', '866', '867', '868', '869', '870', '871', '872', '873', '874', '875', '876', '877', '878', '879', '880', '881', '882', '883', '884', '885', '886', '887', '888', '889', '890', '891', '892', '893', '894', '895', '896', '897', '898', '899', '900', '901', '902', '903', '904', '905', '906', '907', '908', '909', '910', '911', '912', '913', '914', '915', '916', '917', '918', '919', '920', '921', '922', '923', '924', '925', '926', '927', '928', '929', '930', '931', '932', '933', '934', '935', '936', '937', '938', '939', '940', '941', '942', '943', '944', '945', '946', '947', '948', '949', '950', '951', '952', '953', '954', '955', '956', '957', '958', '959', '960', '961', '962', '963', '964', '965', '966', '967', '968', '969', '970', '971', '972', '973', '974', '975', '976', '977', '978', '979', '980', '981', '982', '983', '984', '985', '986', '987', '988', '989', '990', '991', '992', '993', '994', '995', '996', '997', '998', '999', '1000', '1001', '1002', '1003', '1004', '1005', '1006', '1007', '1008', '1009', '1010', '1011', '1012', '1013', '1014', '1015', '1016', '1017', '1018', '1019', '1020', '1021', '1022', '1023', '1024', '1025', '1026', '1027', '1028', '1029', '1030', '1031', '1032', '1033', '1034', '1035', '1036', '1037', '1038', '1039', '1040', '1041', '1042', '1043', '1044', '1045', '1046', '1047', '1048', '1049', '1050', '1051', '1052', '1053', '1054', '1055', '1056', '1057', '1058', '1059', '1060', '1061', '1062', '1063', '1064', '1065', '1066', '1067', '1068', '1069', '1070', '1071', '1072', '1073', '1074', '1075', '1076', '1077', '1078', '1079', '1080', '1081', '1082', '1083', '1084', '1085', '1086', '1087', '1088', '1089', '1090', '1091', '1092', '1093', '1094', '1095', '1096', '1097', '1098', '1099', '1100', '1101', '1102', '1103', '1104', '1105', '1106', '1107', '1108', '1109', '1110', '1111', '1112', '1113', '1114', '1115', '1116', '1117', '1118', '1119', '1120', '1121', '1122', '1123', '1124', '1125', '1126', '1127', '1128', '1129', '1130', '1131', '1132', '1133', '1134', '1135', '1136', '1137', '1138', '1139', '1140', '1141', '1142', '1143', '1144', '1145', '1146', '1147', '1148', '1149', '1150', '1151', '1152', '1153', '1154', '1155', '1156', '1157', '1158', '1159', '1160', '1161', '1162', '1163', '1164', '1165', '1166', '1167', '1168', '1169', '1170', '1171', '1172', '1173', '1174', '1175', '1176', '1177', '1178', '1179', '1180', '1181', '1182', '1183', '1184', '1185', '1186', '1187', '1188', '1189', '1190', '1191', '1192', '1193', '1194', '1195', '1196', '1197', '1198', '1199', '1200', '1201', '1202', '1203', '1204', '1205', '1206', '1207', '1208', '1209', '1210', '1211', '1212', '1213', '1214', '1215', '1216', '1217', '1218', '1219', '1220', '1221', '1222', '1223', '1224', '1225', '1226', '1227', '1228', '1229', '1230', '1231', '1232', '1233', '1234', '1235', '1236', '1237', '1238', '1239', '1240', '1241', '1242', '1243', '1244', '1245', '1246', '1247', '1248', '1249', '1250', '1251', '1252', '1253', '1254', '1255', '1256', '1257', '1258', '1259', '1260', '1261', '1262', '1263', '1264', '1265', '1266', '1267', '1268', '1269', '1270', '1271', '1272', '1273', '1274', '1275', '1276', '1277', '1278', '1279', '1280', '1281', '1282', '1283', '1284', '1285', '1286', '1287', '1288', '1289', '1290', '1291', '1292', '1293', '1294', '1295', '1296', '1297', '1298', '1299', '1300', '1301', '1302', '1303', '1304', '1305', '1306', '1307', '1308', '1309', '1310', '1311', '1312', '1313', '1314', '1315', '1316', '1317', '1318', '1319', '1320', '1321', '1322', '1323', '1324', '1325', '1326', '1327', '1328', '1329', '1330', '1331', '1332', '1333', '1334', '1335', '1336', '1337', '1338', '1339', '1340', '1341', '1342', '1343', '1344', '1345', '1346', '1347', '1348', '1349', '1350', '1351', '1352', '1353', '1354', '1355', '1356', '1357', '1358', '1359', '1360', '1361', '1362', '1363', '1364', '1365', '1366', '1367', '1368', '1369', '1370', '1371', '1372', '1373', '1374', '1375', '1376', '1377', '1378', '1379', '1380', '1381', '1382', '1383', '1384', '1385', '1386', '1387', '1388', '1389', '1390', '1391', '1392', '1393', '1394', '1395', '1396', '1397', '1398', '1399', '1400', '1401', '1402', '1403', '1404', '1405', '1406', '1407', '1408', '1409', '1410', '1411', '1412', '1413', '1414', '1415', '1416', '1417', '1418', '1419', '1420', '1421', '1422', '1423', '1424', '1425', '1426', '1427', '1428', '1429', '1430', '1431', '1432', '1433', '1434', '1435', '1436', '1437', '1438', '1439', '1440', '1441', '1442', '1443', '1444', '1445', '1446', '1447', '1448', '1449', '1450', '1451', '1452', '1453', '1454', '1455', '1456', '1457', '1458', '1459', '1460', '1461', '1462', '1463', '1464', '1465', '1466', '1467', '1468', '1469', '1470', '1471', '1472', '1473', '1474', '1475', '1476', '1477', '1478', '1479', '1480', '1481', '1482', '1483', '1484', '1485', '1486', '1487', '1488', '1489', '1490', '1491', '1492', '1493', '1494', '1495', '1496', '1497', '1498', '1499', '1500', '1501', '1502', '1503', '1504', '1505', '1506', '1507', '1508', '1509', '1510', '1511', '1512', '1513', '1514', '1515', '1516', '1517', '1518', '1519', '1520', '1521', '1522', '1523', '1524', '1525', '1526', '1527', '1528', '1529', '1530', '1531', '1532', '1533', '1534', '1535', '1536', '1537', '1538', '1539', '1540', '1541', '1542', '1543', '1544', '1545', '1546', '1547', '1548', '1549', '1550', '1551', '1552', '1553', '1554', '1555', '1556', '1557', '1558', '1559', '1560', '1561', '1562', '1563', '1564', '1565', '1566', '1567', '1568', '1569', '1570', '1571', '1572', '1573', '1574', '1575', '1576', '1577', '1578', '1579', '1580', '1581', '1582', '1583', '1584', '1585', '1586', '1587', '1588', '1589', '1590', '1591', '1592', '1593', '1594', '1595', '1596', '1597', '1598', '1599', '1600', '1601', '1602', '1603', '1604', '1605', '1606', '1607', '1608', '1609', '1610', '1611', '1612', '1613', '1614', '1615', '1616', '1617', '1618', '1619', '1620', '1621', '1622', '1623', '1624', '1625', '1626', '1627', '1628', '1629', '1630', '1631', '1632', '1633', '1634', '1635', '1636', '1637', '1638', '1639', '1640', '1641', '1642', '1643', '1644', '1645', '1646', '1647', '1648', '1649', '1650', '1651', '1652', '1653', '1654', '1655', '1656', '1657', '1658', '1659', '1660', '1661', '1662', '1663', '1664', '1665', '1666', '1667', '1668', '1669', '1670', '1671', '1672', '1673', '1674', '1675', '1676', '1677', '1678', '1679', '1680', '1681', '1682', '1683', '1684', '1685', '1686', '1687', '1688', '1689', '1690', '1691', '1692', '1693', '1694', '1695', '1696', '1697', '1698', '1699', '1700', '1701', '1702', '1703', '1704', '1705', '1706', '1707', '1708', '1709', '1710', '1711', '1712', '1713', '1714', '1715', '1716', '1717', '1718', '1719', '1720', '1721', '1722', '1723', '1724', '1725', '1726', '1727', '1728', '1729', '1730', '1731', '1732', '1733', '1734', '1735', '1736', '1737', '1738', '1739', '1740', '1741', '1742', '1743', '1744', '1745', '1746', '1747', '1748', '1749', '1750', '1751', '1752', '1753', '1754', '1755', '1756', '1757', '1758', '1759', '1760', '1761', '1762', '1763', '1764', '1765', '1766', '1767', '1768', '1769', '1770', '1771', '1772', '1773', '1774', '1775', '1776', '1777', '1778', '1779', '1780', '1781', '1782', '1783', '1784', '1785', '1786', '1787', '1788', '1789', '1790', '1791', '1792', '1793', '1794', '1795', '1796', '1797', '1798', '1799', '1800', '1801', '1802', '1803', '1804', '1805', '1806', '1807', '1808', '1809', '1810', '1811', '1812', '1813', '1814', '1815', '1816', '1817', '1818', '1819', '1820', '1821', '1822', '1823', '1824', '1825', '1826', '1827', '1828', '1829', '1830', '1831', '1832', '1833', '1834', '1835', '1836', '1837', '1838', '1839', '1840', '1841', '1842', '1843', '1844', '1845', '1846', '1847', '1848', '1849', '1850', '1851', '1852', '1853', '1854', '1855', '1856', '1857', '1858', '1859', '1860', '1861', '1862', '1863', '1864', '1865', '1866', '1867', '1868', '1869', '1870', '1871', '1872']
--------------------------------------------------------------------------- IndexError                                Traceback (most recent call last) <ipython-input-16-03f83ec536c1> in <module>()
     46 print(columns_list)
     47 
---> 48 print(data_dict[0]['x_train'][columns_list].shape)

IndexError: only integers, slices (`:`), ellipsis (`...`), numpy.newaxis (`None`) and integer or boolean arrays are valid indices
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: eunwoo

68517577

Date: 2021-07-25 11:19:23
Score: 1
Natty:
Report link

var hours = ["22:37", "22:52", "23:07", "23:22", "23:37", "23:52", "0:07", "0:22", "0:37", "0:52", "1:07", "1:22", "1:37", "1:52", "2:07", "2:22", "3:07", "3:22", "4:07", "4:22", "4:37", "4:52", "5:07", "5:22", "6:07", "6:22",  "7:07", "7:22", "7:37", "7:52", "8:07", "8:22", "8:37", "8:52", "9:07", "9:22", "9:37", "9:52", "10:07", "10:22", "10:37", "10:52", "11:07", "11:22", "11:37", "11:52", "12:07", "12:22", "14:07", "14:52", "15:07", "15:22", "16:07", "16:22", "16:37", "16:52", "17:07",  "17:52", "18:07", "18:22", "18:37", "18:52", "19:07", "19:22", "19:37", "19:52", "20:07", "20:22", "20:37", "20:52", "21:07", "21:22", "21:37", "21:52", "22:07", "22:22", "22:37", "22:52", "23:07", "23:22"]

var h = {};

for (var hh of hours) {
    try { 
        h[hh.split(':')[0]].push(hh);    
    }
    catch (e) {
        h[hh.split(':')[0]] = [hh];
    }
}

console.log(h);

Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Yuri Khristich

68508330

Date: 2021-07-24 09:43:21
Score: 0.5
Natty:
Report link
import pandas as pd


df = pd.read_json(
    'https://www.bitrates.com/api/node/v1/symbols/USDTUSD/bitrates/series?aggregate=3&period=lastMonth').T['series'].to_dict()['data']
print(pd.DataFrame(df))

Output:

                        date      open     close  ...        supply  market_volume24  btc_ratio
0   2021-04-11T06:00:00.000Z  0.999212  0.999114  ...  4.584629e+10     3.146109e+08   0.000016    
1   2021-04-12T00:00:00.000Z  0.999114  0.999317  ...  4.584629e+10     2.100706e+09   0.000016    
2   2021-06-04T18:00:00.000Z  0.999317  1.000613  ...  6.447629e+10     7.298208e+08   0.000025    
3   2021-06-05T12:00:00.000Z  1.000613  1.000328  ...  0.000000e+00     6.502947e+09   0.000025    
4   2021-06-06T06:00:00.000Z  1.000328  1.000499  ...  6.447629e+10     6.649574e+08   0.000025    
5   2021-06-07T00:00:00.000Z  1.000499  1.000408  ...  6.447629e+10     8.272473e+09   0.000025    
6   2021-06-07T18:00:00.000Z  1.000408  1.000338  ...  6.447629e+10     1.090599e+09   0.000025    
7   2021-06-08T12:00:00.000Z  1.000338  1.000840  ...  6.447177e+10     2.196249e+09   0.000028    
8   2021-06-09T06:00:00.000Z  1.000840  1.001088  ...  0.000000e+00     1.080053e+10   0.000028    
9   2021-06-10T00:00:00.000Z  1.001088  1.000618  ...  6.447177e+10     4.158914e+09   0.000026    
10  2021-06-10T18:00:00.000Z  1.000618  1.000436  ...  6.447177e+10     6.713012e+08   0.000026    
11  2021-06-11T12:00:00.000Z  1.000436  1.000234  ...  6.447177e+10     4.093096e+09   0.000025    
12  2021-06-12T06:00:00.000Z  1.000234  1.000385  ...  6.447177e+10     5.042653e+09   0.000026    
13  2021-06-13T00:00:00.000Z  1.000385  1.000302  ...  0.000000e+00     5.502808e+09   0.000026    
14  2021-06-13T18:00:00.000Z  1.000302  1.000110  ...  6.447177e+10     1.008952e+10   0.000024    
15  2021-06-14T12:00:00.000Z  1.000110  1.000309  ...  6.447177e+10     7.405940e+09   0.000024    
16  2021-06-15T06:00:00.000Z  1.000309  1.000205  ...  6.447177e+10     4.256491e+09   0.000023    
17  2021-06-16T00:00:00.000Z  1.000205  1.000104  ...  0.000000e+00     1.495518e+09   0.000023    
18  2021-06-16T18:00:00.000Z  1.000104  0.999833  ...  0.000000e+00     3.033091e+09   0.000024    
19  2021-06-17T12:00:00.000Z  0.999833  1.000016  ...  6.447177e+10     1.449031e+08   0.000024    
20  2021-07-10T00:00:00.000Z  1.000016  1.000100  ...  6.446977e+10     7.586923e+08   0.000025    
21  2021-07-10T18:00:00.000Z  1.000100  1.000199  ...  6.446977e+10     2.312489e+09   0.000025    
22  2021-07-11T12:00:00.000Z  1.000199  1.000134  ...  6.446977e+10     2.236517e+09   0.000024    
23  2021-07-12T06:00:00.000Z  1.000134  1.000192  ...  6.446977e+10     8.140557e+09   0.000024    
24  2021-07-13T00:00:00.000Z  1.000192  1.000290  ...  6.446977e+10     3.846952e+09   0.000026    
25  2021-07-13T18:00:00.000Z  1.000290  1.000411  ...  6.446977e+10     1.278604e+09   0.000026    
26  2021-07-14T12:00:00.000Z  1.000411  1.000315  ...  6.446977e+10     3.279535e+09   0.000026    
27  2021-07-15T06:00:00.000Z  1.000315  1.000142  ...  6.446977e+10     8.086642e+08   0.000026    
28  2021-07-16T00:00:00.000Z  1.000142  1.000295  ...  6.446977e+10     1.187211e+09   0.000027    
29  2021-07-16T18:00:00.000Z  1.000295  1.000610  ...  6.446977e+10     7.721854e+08   0.000027    
30  2021-07-17T12:00:00.000Z  1.000610  1.000535  ...  6.446977e+10     4.535049e+09   0.000027    
31  2021-07-18T06:00:00.000Z  1.000535  1.000610  ...  6.446977e+10     2.345491e+09   0.000026    
32  2021-07-19T00:00:00.000Z  1.000610  1.000386  ...  6.446977e+10     4.725531e+09   0.000027    
33  2021-07-19T18:00:00.000Z  1.000386  1.000215  ...  6.446977e+10     3.314499e+09   0.000028    
34  2021-07-20T12:00:00.000Z  1.000215  1.000324  ...  6.446977e+10     5.315525e+09   0.000030    
35  2021-07-21T06:00:00.000Z  1.000324  1.000277  ...  6.446977e+10     7.141479e+09   0.000028    
36  2021-07-22T00:00:00.000Z  1.000277  1.000255  ...  6.446977e+10     2.533840e+09   0.000028    
37  2021-07-22T18:00:00.000Z  1.000255  1.000325  ...  6.446977e+10     2.699050e+09   0.000027    
38  2021-07-23T12:00:00.000Z  1.000325  1.000363  ...  6.446977e+10     2.681340e+09   0.000026    
39  2021-07-24T06:00:00.000Z  1.000363  1.000644  ...  6.446974e+10     6.241232e+08   0.000026    

[40 rows x 10 columns]
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: αԋɱҽԃ αмєяιcαη

68493818

Date: 2021-07-23 04:54:47
Score: 1.5
Natty:
Report link

I have a solution with pure python.
first the geometry is a JSON like string,but it has syntax error which the key is single quote,JSON need double quotes,so I parse it by yaml.
Then I just need to format it to list data

import yaml

df = pd.DataFrame({ 'id':[8233037,8233313],
                    'geometry': ["{'type': 'MultiLineString', 'coordinates': [[[107.612018, -6.921755], [107.611888, -6.92303], [107.611715, -6.92473], [107.611715, -6.92489], [107.611729, -6.925015], [107.61177, -6.925134], [107.611872, -6.925277], [107.612596, -6.926166], [107.612923, -6.926555], [107.613084, -6.926826], [107.613086, -6.927077], [107.613064, -6.927535], [107.613061, -6.928426], [107.612968, -6.929409], [107.612932, -6.929788], [107.61285, -6.930428], [107.612796, -6.930606], [107.612681, -6.930843], [107.612386, -6.93127]], [[107.612018, -6.921755], [107.611888, -6.92303], [107.611715, -6.92473], [107.611715, -6.92489], [107.611729, -6.925015], [107.61177, -6.925134], [107.611872, -6.925277], [107.612596, -6.926166], [107.612923, -6.926555], [107.613084, -6.926826], [107.613086, -6.927077], [107.613064, -6.927535], [107.613061, -6.928426], [107.612968, -6.929409], [107.612932, -6.929788], [107.61285, -6.930428], [107.612796, -6.930606], [107.612681, -6.930843], [107.612386, -6.93127]], [[107.612018, -6.921755], [107.611888, -6.92303], [107.611715, -6.92473], [107.611715, -6.92489], [107.611729, -6.925015], [107.61177, -6.925134], [107.611872, -6.925277], [107.612596, -6.926166], [107.612923, -6.926555], [107.613084, -6.926826], [107.613086, -6.927077], [107.613064, -6.927535], [107.613061, -6.928426], [107.612968, -6.929409], [107.612932, -6.929788], [107.61285, -6.930428], [107.612796, -6.930606], [107.612681, -6.930843], [107.612386, -6.93127]], [[107.612018, -6.921755], [107.611888, -6.92303], [107.611715, -6.92473], [107.611715, -6.92489], [107.611729, -6.925015], [107.61177, -6.925134], [107.611872, -6.925277], [107.612596, -6.926166], [107.612923, -6.926555], [107.613084, -6.926826], [107.613086, -6.927077], [107.613064, -6.927535], [107.613061, -6.928426], [107.612968, -6.929409], [107.612932, -6.929788], [107.61285, -6.930428], [107.612796, -6.930606], [107.612681, -6.930843], [107.612386, -6.93127]], [[107.612386, -6.93127], [107.612681, -6.930843], [107.612796, -6.930606], [107.61285, -6.930428], [107.612932, -6.929788], [107.612968, -6.929409], [107.613061, -6.928426], [107.613064, -6.927535], [107.613086, -6.927077], [107.613084, -6.926826], [107.612923, -6.926555], [107.612596, -6.926166], [107.611872, -6.925277], [107.61177, -6.925134], [107.611729, -6.925015], [107.611715, -6.92489], [107.611715, -6.92473], [107.611888, -6.92303], [107.611715, -6.92473], [107.611715, -6.92489], [107.611729, -6.925015], [107.61177, -6.925134], [107.611872, -6.925277], [107.612596, -6.926166], [107.612923, -6.926555], [107.613084, -6.926826], [107.613086, -6.927077], [107.613064, -6.927535], [107.613061, -6.928426], [107.612968, -6.929409], [107.612932, -6.929788], [107.61285, -6.930428], [107.612796, -6.930606], [107.612681, -6.930843], [107.612386, -6.93127]]]}","{'type': 'MultiLineString', 'coordinates': [[[107.614077, -6.91033], [107.614837, -6.910057], [107.615055, -6.909996], [107.615596, -6.909811], [107.616151, -6.909611], [107.617315, -6.90917], [107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853], [107.620936, -6.909341], [107.621119, -6.909319], [107.621369, -6.909287], [107.623747, -6.909832]], [[107.614077, -6.91033], [107.614837, -6.910057], [107.615055, -6.909996], [107.615596, -6.909811], [107.616151, -6.909611], [107.617315, -6.90917], [107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853]], [[107.614077, -6.91033], [107.614837, -6.910057], [107.615055, -6.909996], [107.615596, -6.909811], [107.616151, -6.909611], [107.617315, -6.90917], [107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853]], [[107.614077, -6.91033], [107.614837, -6.910057], [107.615055, -6.909996], [107.615596, -6.909811], [107.616151, -6.909611], [107.617315, -6.90917], [107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853]], [[107.614077, -6.91033], [107.614837, -6.910057], [107.615055, -6.909996], [107.615596, -6.909811], [107.616151, -6.909611], [107.617315, -6.90917], [107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853]], [[107.617315, -6.90917], [107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853], [107.620936, -6.909341], [107.621119, -6.909319], [107.621369, -6.909287], [107.623747, -6.909832]], [[107.617315, -6.90917], [107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853], [107.620936, -6.909341], [107.621119, -6.909319], [107.621369, -6.909287], [107.623747, -6.909832]], [[107.617315, -6.90917], [107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853], [107.620936, -6.909341], [107.621119, -6.909319], [107.621369, -6.909287], [107.623747, -6.909832]], [[107.618309, -6.908848], [107.618488, -6.908803], [107.618645, -6.908796], [107.61901, -6.908853], [107.620936, -6.909341], [107.621119, -6.909319], [107.621369, -6.909287], [107.623747, -6.909832], [107.625456, -6.910273], [107.625764, -6.910353], [107.625871, -6.910358], [107.626035, -6.910264]]]}"]})

data = []
for _,row in df.iterrows():
    id = row['id']
    geo = yaml.load(row['geometry'])['coordinates']
    geos = []
    for g in geo:
        geos += g
    data += [[id,g[0],g[1]] for g in geos]

df_new = pd.DataFrame(data,columns=['id','latitude','longtitude'])
df_new                    
    id      latitude    longtitude
0   8233037 107.612018  -6.921755
1   8233037 107.611888  -6.923030
2   8233037 107.611715  -6.924730
3   8233037 107.611715  -6.924890
4   8233037 107.611729  -6.925015
... ... ... ...
199 8233313 107.623747  -6.909832
200 8233313 107.625456  -6.910273
201 8233313 107.625764  -6.910353
202 8233313 107.625871  -6.910358
203 8233313 107.626035  -6.910264

204 rows × 3 columns
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
Posted by: nay

68483467

Date: 2021-07-22 11:51:59
Score: 0.5
Natty:
Report link

You can group on level 0, and concat the sum per group if the name is not "all", while adding indexes. Then combine this output with the original data and sort_index by level=0:

pd.concat([df,
           pd.concat({(name, 'combined'): d.drop(['Facebook', 'total'], level=1).sum()
                      for name,d in df.groupby(level=0) if name != 'all'}, axis=1).T
          ]).sort_index(level=0)

output:

               2020-06-29 00:00:00                        2020-07-06 00:00:00                        2021-06-28 00:00:00                        2021-07-07 00:00:00                       
                        last_sales       sales difference          last_sales       sales difference          last_sales       sales difference          last_sales       sales difference
group category                                                                                                                                                                            
A     Amazon                 195.0    1268.850        0.0                26.0    3978.150        0.0                96.0    5194.950        0.0                45.0    7556.415        0.0
      Apple                   61.0   18274.385        0.0                39.0   12138.960        0.0                56.0   19102.220        0.0                47.0   14985.050        0.0
      Facebook               106.0   19722.650        0.0                79.0   19084.175        0.0               106.0   22796.420        0.0                87.0   16790.900        0.0
      Google                  61.0   55547.255        0.0                49.0   40033.460        0.0                44.0   30853.115        0.0                45.0   36202.730        0.0
      Netflix                 37.0   15323.800        0.0                10.0    4280.150        0.0                34.0   11461.250        0.0                13.0    4024.970        0.0
      Tesla                   13.0    1688.675        0.0                10.0    1495.100        0.0                13.0     992.600        0.0                 8.0    1034.450        0.0
      Total                  954.0  227463.230        0.0               436.0  165548.290        0.0               716.0  188143.410        0.0               494.0  163960.330        0.0
      Uber                     4.0    1906.000        0.0                 5.0    1764.150        0.0                 9.0    3671.150        0.0                 2.0    1385.650        0.0
      combined              1325.0  321472.195        0.0               575.0  229238.260        0.0               968.0  259418.695        0.0               654.0  229149.595        0.0
      total                  477.0  113731.615        0.0               218.0   82774.145        0.0               358.0   94071.705        0.0               247.0   81980.165        0.0
B     Amazon                  50.0    3219.650        0.0                89.0    8314.920        0.0               101.0    6022.300        0.0                81.0    5600.545        0.0
      Apple                   50.0   15852.060        0.0                34.0   12776.650        0.0                22.0    7373.600        0.0                36.0   11209.920        0.0
      Facebook                75.0   17743.700        0.0               133.0   28048.075        0.0               120.0   33514.000        0.0               143.0   32832.610        0.0
      Google                  43.0   37795.150        0.0                66.0   55104.210        0.0                40.0   35943.450        0.0                56.0   42137.445        0.0
      Netflix                 17.0    5918.500        0.0                21.0    6962.845        0.0                13.0    4749.000        0.0                 9.0    3885.150        0.0
      Tesla                   14.0    1708.750        0.0                20.0    3053.200        0.0                 8.0     902.010        0.0                 9.0    1191.500        0.0
      Total                  504.0  166349.640        0.0               732.0  231049.110        0.0               610.0  177707.320        0.0               670.0  194912.340        0.0
      Uber                     3.0     937.010        0.0                 3.0    1264.655        0.0                 1.0     349.300        0.0                 1.0     599.000        0.0
      combined               681.0  231780.760        0.0               965.0  318525.590        0.0               795.0  233046.980        0.0               862.0  259535.900        0.0
      total                  252.0   83174.820        0.0               366.0  115524.555        0.0               305.0   88853.660        0.0               335.0   97456.170        0.0
all   Total                 2916.0  787625.740        0.0              2336.0  793194.800        0.0              2652.0  731701.460        0.0              2328.0  717745.340        0.0
      total                 2916.0  787625.740        0.0              2336.0  793194.800        0.0              2652.0  731701.460        0.0              2328.0  717745.340        0.0
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: mozway

68480351

Date: 2021-07-22 07:55:10
Score: 4.5
Natty:
Report link

Я столкнулся с этим при разработке на Django, при переходе на другую машину. На новой машине использовал слишком низкую версию python в виртуальном окружении. Получилось, что Django сериализовал какие-то свои объекты по 5-му протоколу (на старом ПК), а десериализовать (на новом ПК при запуске) я их хотел по четвертому. При установке виртуальной среды с python3.9.1 проект успешно запустился.

Reasons:
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Pavel Noskov

68462684

Date: 2021-07-21 01:25:20
Score: 1.5
Natty:
Report link

You already have your answer, but just for fun here's an alternative solution that makes use of TreeMaps instead of a grid.

Note that this code works should the wave descend below the starting point, e.g. if the 2nd, down segment was 17 instead of 7.

public static void main(String[] args)
{
  int[] arr = new int[]{10, 7, 12, 2, 4, 7, 2, 4, 1, 2, 6, 6, 3, 2, 1, 4, 7, 2, 7, 3, 1, 3, 11, 4, 2, 1, 5, 2, 3, 3, 3, 6, 1, 3, 9, 5, 2, 1, 2, 11, 9, 2, 3, 8,2, 5, 1, 2, 7, 2, 4, 11, 2, 12};

  TreeMap<Integer, Integer> col = new TreeMap<>(Collections.reverseOrder());
  
  for(int i=0,c=0,h=0,d=1; i<arr.length; i++,d=-d,h+=d)
    for(int j=0; j<arr[i]; j++,c++,h+=d)
        col.put(d*c, h);
  
  TreeMap<Integer, List<Integer>> row = new TreeMap<>(Collections.reverseOrder());
  for(Entry<Integer, Integer> e : col.entrySet())
  {
    List<Integer> ll = row.get(e.getValue());
    if(ll == null) row.put(e.getValue(), ll = new ArrayList<>());
    ll.add(e.getKey());
  }
  
  int rows = 1 + row.firstEntry().getKey() - row.lastEntry().getKey();
  int cols = 1 + Math.abs(col.lastEntry().getKey());
  char[] line = new char[cols];
  Arrays.fill(line, ' ');
  
  System.out.printf("rows = %d, cols = %d%n", rows, cols);
  for(List<Integer> p : row.values())
  {
    for(int i : p) line[Math.abs(i)] = i >= 0 ? '/' : '\\';
    System.out.println(new String(line));
    for(int i : p) line[Math.abs(i)] = ' ';
  }
}

Output:

rows = 27, cols = 240
                                                                                                                                                    /\                                                                                          
                                                                                                                           /\    /\                /  \                                                                                         
                                                                                                                      /\  /  \  /  \              /    \      /\                                                                                
                                                                                                                     /  \/    \/    \            /      \  /\/  \                      /\                                                       
                                                                                                          /\        /                \          /        \/      \                /\  /  \                                                      
                                                                                                         /  \      /                  \        /                  \              /  \/    \                                                     
                                                                                                        /    \  /\/                    \/\    /                    \            /          \                          /\                        
                                                                                                       /      \/                          \  /                      \          /            \                        /  \                       
                                                                                                      /                                    \/                        \        /              \                  /\  /    \                      
                                                                                                     /                                                                \      /                \  /\            /  \/      \                     
                                  /\                                                    /\          /                                                                  \    /                  \/  \          /            \                    
                                 /  \                                                  /  \        /                                                                    \  /                        \        /              \                   
                            /\  /    \                                                /    \/\    /                                                                      \/                          \      /                \                  
                           /  \/      \                                              /        \  /                                                                                                    \/\  /                  \                 
                          /            \                /\                          /          \/                                                                                                        \/                    \                
                         /              \  /\          /  \                    /\  /                                                                                                                                            \  /\           
                        /                \/  \        /    \                  /  \/                                                                                                                                              \/  \          
         /\            /                      \      /      \    /\          /                                                                                                                                                        \         
        /  \          /                        \/\  /        \  /  \/\      /                                                                                                                                                          \        
       /    \        /                            \/          \/      \    /                                                                                                                                                            \       
      /      \      /                                                  \  /                                                                                                                                                              \      
     /        \    /                                                    \/                                                                                                                                                                \     
    /          \  /                                                                                                                                                                                                                        \    
   /            \/                                                                                                                                                                                                                          \   
  /                                                                                                                                                                                                                                          \  
 /                                                                                                                                                                                                                                            \ 
/                                                                                                                                                                                                                                              \
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low entropy (1):
  • High reputation (-1):
Posted by: RaffleBuffle

68461976

Date: 2021-07-20 23:25:25
Score: 0.5
Natty:
Report link

Finally figured it out. It appears you can't use a FeatureCollection directly as the source of a mapbox layer. At least, I couldn't figure out how.

Instead, I needed to create a layer for each individual feature in the feature collection. Here is a full working example:

import geojson
import plotly.express as px
import plotly.graph_objects as go
from IPython.display import Image

def estimate_center_of_FeatureCollection(featureCollection):
    lats = [xy[1] for feature in featureCollection['features'] for xy in feature['coordinates']]
    lons = [xy[0] for feature in featureCollection['features'] for xy in feature['coordinates']]

    center_lat = (min(lats) + max(lats)) / 2
    center_lon = (min(lons) + max(lons)) / 2
    
    return center_lon, center_lat


featureCollection = geojson.FeatureCollection([{"type": "LineString", "coordinates": [[42.606938, -0.248537], [42.606992, -0.248266], [42.6071, -0.247995], [42.607207, -0.247724], [42.607315, -0.247453], [42.607477, -0.247182], [42.607692, -0.24691], [42.607908, -0.246639], [42.608177, -0.246368], [42.608447, -0.246151], [42.608716, -0.245934], [42.608986, -0.245718], [42.609255, -0.245555], [42.609524, -0.245392], [42.609794, -0.245175], [42.610063, -0.244958], [42.610333, -0.244796], [42.610602, -0.244579], [42.610871, -0.244362], [42.611141, -0.244199], [42.61141, -0.244037], [42.61168, -0.243874], [42.611949, -0.243766], [42.612218, -0.243711], [42.612488, -0.243603], [42.612757, -0.243549], [42.613026, -0.243495], [42.613296, -0.24344], [42.613565, -0.243332], [42.613835, -0.243332], [42.614104, -0.243278], [42.614373, -0.243224], [42.614643, -0.243115], [42.614912, -0.243115], [42.615182, -0.243007], [42.615451, -0.242898], [42.61572, -0.24279], [42.61599, -0.242736], [42.616259, -0.242627], [42.616528, -0.242519], [42.616798, -0.242465], [42.617067, -0.242411], [42.617337, -0.242302], [42.617606, -0.242194], [42.617875, -0.24214], [42.618145, -0.24214], [42.618414, -0.242085], [42.618684, -0.242031], [42.618953, -0.241977], [42.619222, -0.241923], [42.619492, -0.241869], [42.619761, -0.241814], [42.62003, -0.241814], [42.6203, -0.241815], [42.620569, -0.24176], [42.620839, -0.241706], [42.621108, -0.241652], [42.621377, -0.241544], [42.621647, -0.241435], [42.621916, -0.241327], [42.622186, -0.24111], [42.622455, -0.240893], [42.622724, -0.240676], [42.622886, -0.240405], [42.622994, -0.240134], [42.623048, -0.239862], [42.622994, -0.239591], [42.622832, -0.23932], [42.622725, -0.239049], [42.622348, -0.238615], [42.622348, -0.238615], [42.622132, -0.238452], [42.622132, -0.238452], [42.621647, -0.238127], [42.621378, -0.237964], [42.621109, -0.237747], [42.620839, -0.23753], [42.62057, -0.237313], [42.620301, -0.23715], [42.620031, -0.237042], [42.619762, -0.236879], [42.619493, -0.23677], [42.619223, -0.236716], [42.618954, -0.236662], [42.618684, -0.236553], [42.618415, -0.236499], [42.618146, -0.23639], [42.617876, -0.236282], [42.617445, -0.235956], [42.617445, -0.235956], [42.617284, -0.235739], [42.617284, -0.235739], [42.616961, -0.235251], [42.616853, -0.23498], [42.616638, -0.234709], [42.616422, -0.234438], [42.616261, -0.234166], [42.616099, -0.233895], [42.615883, -0.233624], [42.615668, -0.233353], [42.61556, -0.233082], [42.615453, -0.23281], [42.615399, -0.232539], [42.615399, -0.232268], [42.615453, -0.231997], [42.615453, -0.231726], [42.615453, -0.231454], [42.615453, -0.231183], [42.615399, -0.230912], [42.615345, -0.230641], [42.615291, -0.23037], [42.615238, -0.230099], [42.615184, -0.229827], [42.615184, -0.229556], [42.615184, -0.229285], [42.615184, -0.229014], [42.615184, -0.228743], [42.615184, -0.228471], [42.615184, -0.2282], [42.61513, -0.227929], [42.615076, -0.227658], [42.615023, -0.227387], [42.614969, -0.227115], [42.614915, -0.226844], [42.614915, -0.226573], [42.614915, -0.226302], [42.614915, -0.226031], [42.614915, -0.22576], [42.614915, -0.225488], [42.614915, -0.225217], [42.614915, -0.224946], [42.614915, -0.224675], [42.614915, -0.224404], [42.614915, -0.224132], [42.614915, -0.223861], [42.614969, -0.22359], [42.615023, -0.223319], [42.615077, -0.223048], [42.615185, -0.222777], [42.615293, -0.222505], [42.615347, -0.222234], [42.615454, -0.221963], [42.615562, -0.221692], [42.61567, -0.221421], [42.615778, -0.22115], [42.615939, -0.220878], [42.616047, -0.220607], [42.616209, -0.220336], [42.616317, -0.220065], [42.616478, -0.219794], [42.61664, -0.219577], [42.616856, -0.21936], [42.616856, -0.21936], [42.617233, -0.218926], [42.617341, -0.218709], [42.617394, -0.218438], [42.617448, -0.218167], [42.617502, -0.217896], [42.61761, -0.217625], [42.617772, -0.217353], [42.617933, -0.217082], [42.618095, -0.216811], [42.618203, -0.21654], [42.618311, -0.216269], [42.618365, -0.215998], [42.618418, -0.215726], [42.618419, -0.215455], [42.618419, -0.215184], [42.618419, -0.214913], [42.618419, -0.214642], [42.618365, -0.21437], [42.618311, -0.214099], [42.618257, -0.213828], [42.618149, -0.213557], [42.617988, -0.213286], [42.61788, -0.213014], [42.617719, -0.212743], [42.617557, -0.212472], [42.617395, -0.212201], [42.617288, -0.21193], [42.617126, -0.211658], [42.616965, -0.211387], [42.616803, -0.211116], [42.616641, -0.210845], [42.616426, -0.210574], [42.61621, -0.210302], [42.615995, -0.210031], [42.615726, -0.20976], [42.615456, -0.209489], [42.615187, -0.209217], [42.614972, -0.208946], [42.614756, -0.208675], [42.614541, -0.208404], [42.614325, -0.208133], [42.61411, -0.207861], [42.613894, -0.20759], [42.613733, -0.207319], [42.613571, -0.207048], [42.61341, -0.206777], [42.613302, -0.206505], [42.61314, -0.206234], [42.612925, -0.205963], [42.612709, -0.205692], [42.612494, -0.20542], [42.612225, -0.205149], [42.611955, -0.204878], [42.611686, -0.204607], [42.611417, -0.204336], [42.611147, -0.204064], [42.610878, -0.203793], [42.610609, -0.203522], [42.610339, -0.203251], [42.61007, -0.202979], [42.609801, -0.202763], [42.609531, -0.202654], [42.609262, -0.202545], [42.608993, -0.202437], [42.608723, -0.202328], [42.608454, -0.202166], [42.608185, -0.201894], [42.607969, -0.201623], [42.607754, -0.201352], [42.607592, -0.201081], [42.60743, -0.20081], [42.607323, -0.200538], [42.607215, -0.200267], [42.607161, -0.199996], [42.607053, -0.199725], [42.607, -0.199454], [42.606946, -0.199182], [42.606892, -0.198911], [42.606838, -0.19864], [42.606892, -0.198369], [42.606946, -0.198098], [42.607, -0.197827], [42.607054, -0.197555], [42.607162, -0.197284], [42.607215, -0.197013], [42.607269, -0.196742], [42.607377, -0.196471], [42.607539, -0.1962], [42.607647, -0.195928], [42.607808, -0.195657], [42.608024, -0.195386], [42.608239, -0.195115], [42.608455, -0.194844], [42.60867, -0.194573], [42.609101, -0.194085], [42.609101, -0.194085], [42.609317, -0.193868], [42.609317, -0.193868], [42.609802, -0.193434], [42.610071, -0.193271], [42.610341, -0.193054], [42.61061, -0.192837], [42.61088, -0.19262], [42.611095, -0.192404], [42.611311, -0.192132], [42.611526, -0.191861], [42.611688, -0.19159], [42.611849, -0.191319], [42.612065, -0.191048], [42.612227, -0.190777], [42.612388, -0.190505], [42.61255, -0.190234], [42.612712, -0.189963], [42.612873, -0.189692], [42.613035, -0.189421], [42.613143, -0.18915], [42.61325, -0.188878], [42.613358, -0.188607], [42.613412, -0.188336], [42.613466, -0.188065], [42.61352, -0.187794], [42.613628, -0.187523], [42.613682, -0.187251], [42.613736, -0.18698], [42.61379, -0.186709], [42.613843, -0.186438], [42.613843, -0.186167], [42.613844, -0.185896], [42.613897, -0.185624], [42.613951, -0.185353], [42.614005, -0.185082], [42.614113, -0.184811], [42.614221, -0.18454], [42.614275, -0.184269], [42.614383, -0.183997], [42.61449, -0.183726], [42.614598, -0.183455], [42.614706, -0.183184], [42.614868, -0.182913], [42.614975, -0.182642], [42.615083, -0.18237], [42.615191, -0.182099], [42.615353, -0.181828], [42.615514, -0.181557], [42.615676, -0.181286], [42.615891, -0.181015], [42.616107, -0.180743], [42.616215, -0.180472], [42.616269, -0.180201], [42.616269, -0.17993], [42.616161, -0.179659], [42.615945, -0.179387], [42.61573, -0.179116], [42.615461, -0.178845], [42.615191, -0.178574], [42.614922, -0.178357], [42.614653, -0.178194], [42.614383, -0.178086], [42.614114, -0.177977], [42.613845, -0.177923], [42.613575, -0.177814], [42.613306, -0.177706], [42.613036, -0.177597], [42.612767, -0.177543], [42.612498, -0.177489], [42.612228, -0.177489], [42.611959, -0.177489], [42.61169, -0.177489], [42.61142, -0.177489], [42.611151, -0.177489], [42.610882, -0.177489], [42.610612, -0.177488], [42.610343, -0.177488], [42.610073, -0.177434], [42.609804, -0.17738], [42.609535, -0.177326], [42.609265, -0.177271], [42.608996, -0.177163], [42.608727, -0.177109], [42.608457, -0.177054], [42.608188, -0.176946], [42.607919, -0.176837], [42.607649, -0.176783], [42.60738, -0.176675], [42.607111, -0.176566], [42.606841, -0.176566], [42.606572, -0.176512], [42.606302, -0.176457], [42.606033, -0.176457], [42.605764, -0.176512], [42.605494, -0.176512], [42.605225, -0.176566], [42.604956, -0.176566], [42.60474, -0.176511], [42.604525, -0.176349], [42.604309, -0.176132], [42.604201, -0.175861], [42.604094, -0.175589], [42.603932, -0.175318], [42.603824, -0.175047], [42.603717, -0.174776], [42.603555, -0.174505], [42.603447, -0.174233], [42.60334, -0.173962], [42.603232, -0.173691], [42.603124, -0.17342], [42.603017, -0.173149], [42.602909, -0.172877], [42.602855, -0.172606], [42.602855, -0.172335], [42.602855, -0.172064], [42.602855, -0.171793], [42.602855, -0.171522], [42.602855, -0.17125], [42.602801, -0.170979], [42.602801, -0.170708], [42.602748, -0.170437], [42.602694, -0.170166], [42.60264, -0.169894], [42.602586, -0.169623], [42.602478, -0.169352], [42.602424, -0.169081]]}])


fig = go.Figure(
    go.Scattermapbox(),
    layout = {
        'mapbox': {
            'style': "stamen-terrain",
            'zoom': 10
        },
        'margin': {'l':0, 'r':0, 'b':0, 't':0},
    }
)

fig.update_mapboxes(layers=[
    {
        'source': feature, 
        'type': "line", 
        'line': {'width': 5},
        'below': "traces", 
        'color': "royalblue"
    } for feature in featureCollection.features])

center_lon, center_lat = estimate_center_of_FeatureCollection(featureCollection)

fig.update_layout(
    mapbox = {
        'center': { 'lon':  center_lon, 'lat': center_lat}
    }
)

Image(fig.to_image(format="png", width=600, height=600))

The result is:
Map with linestring rendered

Reasons:
  • Blacklisted phrase (0.5): I need
  • Long answer (-1):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • High reputation (-2):
Posted by: FGreg

68456720

Date: 2021-07-20 15:38:42
Score: 4.5
Natty:
Report link

Thanks! I've made it via schedule_work.

struct my_data {
    /* data */
    struct work_struct remove_proc_work;
};

static void remove_proc_work_handler(struct work_struct *work)                                                                                                                                                                                                                  
{                                                                                                                                                                                                                                                                               
        struct my_data *data;                                                                                                                                                                                                                                                  
                                                                                                                                                                                                                                                                                
        data = container_of(work, struct my_data, remove_proc_work);                                                                                                                                                                                                           
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            
        /* call remove_proc_entry */                                                                                                                                                                                                                                     
} 

static void init_data(struct my_data *data)
{
    /* init data */
    INIT_WORK(&data->remove_proc_work, remove_proc_work_handler);
}

static int my_write(struct file *file, const char __user *userbuff,                                                                                                                                                                                                             
                    size_t len, loff_t *ppos)                                                                                                                                                                                                                                   
{                                                                                                                                                                                                                                                                               
        struct  seq_file *seqf = file->private_data;                                                                                                                                                                                                                             
        struct *my_data = seqf->private;                                                                                                                                                                                                                                        
        char   *buff;                                                                                                                                                                                                                                                            
        int     retval;                                                                                                                                                                                                                                                          
                                                                                                                                                                                                                                                                                
        retval = -EINVAL;                                                                                                                                                                                                                                                       
                                                                                                                                                                                                                                                                                
        if (!userbuff || len > PAGE_SIZE)                                                                                                                                                                                                                                       
                return -EINVAL;                                                                                                                                                                                                                                                 
                                                                                                                                                                                                                                                                                
        buff = kzalloc((len + 1), GFP_KERNEL);                                                                                                                                                                                                                                  
        if (!buff)                                                                                                                                                                                                                                                              
                return -ENOMEM;                                                                                                                                                                                                                                                 
                                                                                                                                                                                                                                                                                
        if (copy_from_user(buff, userbuff, len))                                                                                                                                                                                                                                
                goto out;                                                                                                                                                                                                                                                       
                                                                                                                                                                                                                                                                                
        buff[len] = '\0';                                                                                                                                                                                                                                                       
                                                                                                                                                                                                                                                                                
        if (!strncmp("delete", buff, 6)) {                                                                                                                                                                                                                                      
                /* Cannot use remove_proc_entry inside that write callback. */                          
                schedule_work(&data->remove_proc_work);                                                                                                                                                       
                retval = 0;                                                                                                                                                                                                                                                     
        }                                                                                                                                                                                                                                                                       
                                                                                                                                                                                                                                                                                
        if (!retval)                                                                                                                                                                                                                                                            
                retval = len;                                                                                                                                                                                                                                                   
        else                                                                                                                                                                                                                                                                    
                printk("Usage: echo delete > /proc/my_proc to delete that entry.\n");                                                                                                                                                                                          
                                                                                                                                                                                                                                                                                
        return retval;                                                                                                                                                                                                                                                          
}                                                                                                                                                                                                                                                                               
                                                                                                                                                                                                                                                                                
static const struct file_operations my_proc_fops = {                                                                                                                                                                                                                            
        .open    = my_proc_open,                                                                                                                                                                                                                                                
        .read    = seq_read,                                                                                                                                                                                                                                                    
        .write   = my_write,                                                                                                                                                                                                                                                    
        .llseek  = seq_lseek,                                                                                                                                                                                                                                                   
        .release = single_release,                                                                                                                                                                                                                                              
};  
Reasons:
  • Blacklisted phrase (0.5): Thanks
  • Long answer (-1):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • Low entropy (1):
  • Low reputation (1):
Posted by: Ivan Morozko

68456360

Date: 2021-07-20 15:14:56
Score: 5
Natty:
Report link

Here's my sample:

Cost
170,48
299,28
428,08
556,88
685,68
814,48
943,28
1072,08
1.136,48
1.200,88
1.329,68
1.458,48
1.587,28
1.716,08
1.844,88
1.973,68
2.102,48
2.231,28
2.360,08
2.488,88
5.193,68
170,48
299,28
428,08
556,88
685,68
814,48
943,28
1072,08
Reasons:
  • No code block (0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: user16429309

68451063

Date: 2021-07-20 08:31:56
Score: 1
Natty:
Report link

Use a list to select rows [1, 3]:

>>> df
          0         1         2         3         4
0  0.009261  0.086365  0.593328  0.720758  0.737400
1  0.524058  0.082033  0.878503  0.207533  0.604475
2  0.153760  0.550047  0.541319  0.820629  0.723249
3  0.748347  0.978250  0.873707  0.566690  0.818272
4  0.195021  0.132876  0.484904  0.792552  0.149720
df.iloc[[1, 3]] = 1
>>> df
          0         1         2         3         4
0  0.009261  0.086365  0.593328  0.720758  0.737400
1  1.000000  1.000000  1.000000  1.000000  1.000000  # <- all 1
2  0.153760  0.550047  0.541319  0.820629  0.723249
3  1.000000  1.000000  1.000000  1.000000  1.000000  # <- all 1
4  0.195021  0.132876  0.484904  0.792552  0.149720
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Corralien

68449462

Date: 2021-07-20 05:14:58
Score: 5.5
Natty:
Report link

كُلَّ عَامٍ وَأَنْتُم بِأَلْف خَيْرٌ تَقَبَّلَ اللَّهُ منا ومنكم طَاعَتَكُم عِيدِ الْأَضْحَى مُبَارَكٌ عَلَيْكُم وَأَعَادَه اللَّهُ عَلَيْكُمْ مَرَّات وَمَرَّات وَكُرَّات وَكُرَّات وَأَنْتُم بِخَيْر وَصِحَّة وسعادة وَعَافِيَة شكرا شكرا شكرا لكم أحبائي وأصدقائي وزملائي على تهنئتكم ورق مشاعركم حفظكم الله ورعاكم 🙏🙏💓💓🌹🌹❤️❤️🥰🥰🙏🌹 محبكم 🥰🌹🤲 ( صبحي أبولوز )

Reasons:
  • Blacklisted phrase (0.5): 🙏
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Sobhi aboulouz

68449393

Date: 2021-07-20 05:02:36
Score: 6.5
Natty:
Report link

[>=10000]#,##0,"K";0

Reasons:
  • Low length (2):
  • No code block (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: Bharat

68443412

Date: 2021-07-19 16:51:42
Score: 0.5
Natty:
Report link

Input data:

>>> df
       0      1      2      3      4      5      6      7      8      9
0  72.76  47.54  57.37  40.03  75.24  46.05  51.76  33.94  56.97  78.77
1  52.54  79.47  42.52  31.36  40.38  47.65  34.89  57.98  40.27  59.65
2  72.61  48.26  35.68  43.54  32.07  60.47  71.90  85.41  40.66  48.70
3  62.56  72.92  50.90  38.44  48.64  47.35  69.55  65.00  30.74  63.12
4  27.59  45.57  55.75  66.59  60.69  60.99  49.23  45.16  33.03  29.38

Difference between the first row and other ones:

>>> df - df.iloc[0]
       0      1      2      3      4      5      6      7      8      9
0   0.00   0.00   0.00   0.00   0.00   0.00   0.00   0.00   0.00   0.00
1 -20.22  31.93 -14.85  -8.67 -34.86   1.60 -16.87  24.04 -16.70 -19.12
2  -0.15   0.72 -21.69   3.51 -43.17  14.42  20.14  51.47 -16.31 -30.07
3 -10.20  25.38  -6.47  -1.59 -26.60   1.30  17.79  31.06 -26.23 -15.65
4 -45.17  -1.97  -1.62  26.56 -14.55  14.94  -2.53  11.22 -23.94 -49.39

Convert to a list:

>>> df.values.tolist()
[[72.76, 47.54, 57.37, 40.03, 75.24, 46.05, 51.76, 33.94, 56.97, 78.77],
 [52.54, 79.47, 42.52, 31.36, 40.38, 47.65, 34.89, 57.98, 40.27, 59.65],
 [72.61, 48.26, 35.68, 43.54, 32.07, 60.47, 71.9, 85.41, 40.66, 48.7],
 [62.56, 72.92, 50.9, 38.44, 48.64, 47.35, 69.55, 65.0, 30.74, 63.12],
 [27.59, 45.57, 55.75, 66.59, 60.69, 60.99, 49.23, 45.16, 33.03, 29.38]]

Difference as a list: df.sub(df.iloc[0]).values.tolist()

Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Corralien

68440491

Date: 2021-07-19 13:32:11
Score: 2
Natty:
Report link

I would do this:

import numpy as np

np.random.seed(0)
data = np.random.randint(10, size = (3, 3, 3, 3))

normalized_data = (data - data.min((2, 3)).reshape(3, 3, 1, 1))/(data.max((2, 3)) - data.min((2, 3))).reshape(3, 3, 1, 1)

output:

data = 
[[[[5 0 3]
   [3 7 9]
   [3 5 2]]

  [[4 7 6]
   [8 8 1]
   [6 7 7]]

  [[8 1 5]
   [9 8 9]
   [4 3 0]]]


 [[[3 5 0]
   [2 3 8]
   [1 3 3]]

  [[3 7 0]
   [1 9 9]
   [0 4 7]]

  [[3 2 7]
   [2 0 0]
   [4 5 5]]]


 [[[6 8 4]
   [1 4 9]
   [8 1 1]]

  [[7 9 9]
   [3 6 7]
   [2 0 3]]

  [[5 9 4]
   [4 6 4]
   [4 3 4]]]]
normalized_data = 
[[[[0.55555556 0.         0.33333333]
   [0.33333333 0.77777778 1.        ]
   [0.33333333 0.55555556 0.22222222]]

  [[0.42857143 0.85714286 0.71428571]
   [1.         1.         0.        ]
   [0.71428571 0.85714286 0.85714286]]

  [[0.88888889 0.11111111 0.55555556]
   [1.         0.88888889 1.        ]
   [0.44444444 0.33333333 0.        ]]]


 [[[0.375      0.625      0.        ]
   [0.25       0.375      1.        ]
   [0.125      0.375      0.375     ]]

  [[0.33333333 0.77777778 0.        ]
   [0.11111111 1.         1.        ]
   [0.         0.44444444 0.77777778]]

  [[0.42857143 0.28571429 1.        ]
   [0.28571429 0.         0.        ]
   [0.57142857 0.71428571 0.71428571]]]


 [[[0.625      0.875      0.375     ]
   [0.         0.375      1.        ]
   [0.875      0.         0.        ]]

  [[0.77777778 1.         1.        ]
   [0.33333333 0.66666667 0.77777778]
   [0.22222222 0.         0.33333333]]

  [[0.33333333 1.         0.16666667]
   [0.16666667 0.5        0.16666667]
   [0.16666667 0.         0.16666667]]]]
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: yann ziselman

68437802

Date: 2021-07-19 10:07:59
Score: 1.5
Natty:
Report link

Example below:

const baseArray = [ 1, 2, 3, 4, 5, 6, 7, 7, 7, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 12, 12, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 13, 13, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 1, 2, 3, 4, 5, 6, 6, 6, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 10, 10, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 1, 2, 3, 4, 5, 6, 6, 6, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 1, 2, 3, 4, 5, 6, 7, 8, 9, 9, 9, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 10, 10, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 11, 11, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 1, 2, 3, 4, 5, 5, 5, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, ];

const output = baseArray
  .join(",")
  .split(",1,")
  .map(el => Array.from(new Set(("1," + el).split(","))));

console.log(output);

Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
Posted by: ikhvjs

68427545

Date: 2021-07-18 10:04:08
Score: 0.5
Natty:
Report link

Not sure what you are doing but you file can be fixed using column -t < filename command.

Example :

❯ cat test
H   18.38385    15.26701    2.28399
C   19.32295    15.80772    2.28641
O   16.69023    17.37471    2.23138
H   22.72612    1.13322 2.17619
C   14.47116    18.37823    2.18809
C   15.85803    18.42398    2.20614
C   20.51484    15.08859    2.30584
C   22.77653    3.65203 2.19000
C   19.33725    17.20040    2.26894
C   23.01832    9.16815 2.25575
C   23.48143    2.42830 2.16161
H   22.07113    11.03567    2.32659
C   13.75496    19.59644    2.16380
O   23.01248    6.08053 2.20226
C   12.41476    19.56937    2.14732
C   16.54400    19.61620    2.20021
C   23.50500    4.83405 2.17735
H   23.03249    10.56089    2.28599
O   17.87129    19.42333    2.22107

~ 
❯ column -t  < test
H  18.38385  15.26701  2.28399
C  19.32295  15.80772  2.28641
O  16.69023  17.37471  2.23138
H  22.72612  1.13322   2.17619
C  14.47116  18.37823  2.18809
C  15.85803  18.42398  2.20614
C  20.51484  15.08859  2.30584
C  22.77653  3.65203   2.19000
C  19.33725  17.20040  2.26894
C  23.01832  9.16815   2.25575
C  23.48143  2.42830   2.16161
H  22.07113  11.03567  2.32659
C  13.75496  19.59644  2.16380
O  23.01248  6.08053   2.20226
C  12.41476  19.56937  2.14732
C  16.54400  19.61620  2.20021
C  23.50500  4.83405   2.17735
H  23.03249  10.56089  2.28599
O  17.87129  19.42333  2.22107

~ 
❯ 
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Digvijay S

68426640

Date: 2021-07-18 07:39:51
Score: 4.5
Natty:
Report link

Az pakistan in urdu.

السلام اپ کا بہت شکریہ ان فارمولوں میں یہ ہوتا ہے کہ مثلاًکلاس میں 50 طلبہ ہیں اگرکلاس کے ان 50 طلبہ میں سے 8 طلبہ نے دسویں پوزیشن حاصل کی ہے تویہ فارمولے ان8 طلبہ کو کلاس پوزیشن10 میں دکھا دیں گے لیکن اس کے بعد 11 سے لے کر 20 تک کلاس پوزیشن نہیں دیکھاتے ہیں بلکہ کلاس پوزیشن 11 کو 21 پر دکھائیں گے۔ تو پوچھنا یہ ہے کہ کیا آپ کے پاس ایسا فارمولا ہے جو ترتیب سے دیکھا دیں ؟ یامثلاً کلاس میں دو طلبہ نے پہلی پوزیشن حاصل کی ہے اس فارمولے میں تیسر پوزیشن حاصل کرنے والے کو نہیں دکھاتےبلکہ تیسری پوزیشن کو چوتھے پوزیشن میں دکھاتے ہیں ، کیا ایسا ہوسکتا ہے کہ تیسری پوزیشن والے کو دکھادیں، شکریہ

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: user16472830

68417083

Date: 2021-07-17 04:08:54
Score: 0.5
Natty:
Report link

Solution

Step-1: Use a dict as follows to store your data.

params_dict = {
    'RSI': {
        'parameter': [range(13,16,1), range(70,80,5), range(25,35,5)],
        'params_list': None,
    },
    'Bollinger': {
        'parameter': [range(20,35,1),np.arange(2,3,0.25)],
        'params_list': None,
    },
    'MACD': {
        'parameter': [range(11,14,1),range(25,27,1),range(9,11,1)],
        'params_list': None,
    },
    'EMA': {
        'parameter': [range(20,21,1),range(50,51,1),np.arange(0,0.01,0.002)],
        'params_list': None,
    },
}

for label in params_dict:
    params_dict[label]['params_list'] = list(itertools.product(*params_dict[label]['parameter']))

Step-2: Adapt the code to use the dict.

indiclist=[]
for i in range(1,5):
    for item in itertools.combinations(('RSI','Bollinger','MACD','EMA'),i):
        indiclist.append(list(item))
print(indiclist)

Step-3: The following block will give what you are looking for.

params = []
for labels in indiclist:
    for label in labels:
        params.append(params_dict[label]['params_list'])

print(params)

Output:

[[(13, 70, 25),
  (13, 70, 30),
  (13, 75, 25),
  (13, 75, 30),
  (14, 70, 25),
  (14, 70, 30),
  (14, 75, 25),
  (14, 75, 30),
  (15, 70, 25),
  (15, 70, 30),
  (15, 75, 25),
  (15, 75, 30)],
 [(20, 2.0),
  (20, 2.25),
  (20, 2.5),
  (20, 2.75),
  (21, 2.0),
  (21, 2.25),
  (21, 2.5),
  (21, 2.75),
  (22, 2.0),
  (22, 2.25),
  (22, 2.5),
  (22, 2.75),
  (23, 2.0),
  (23, 2.25),
  (23, 2.5),
  (23, 2.75),
  (24, 2.0),
  (24, 2.25),
  (24, 2.5),
  (24, 2.75),
  (25, 2.0),
  (25, 2.25),
  (25, 2.5),
  (25, 2.75),
  (26, 2.0),
  (26, 2.25),
  (26, 2.5),
  (26, 2.75),
  (27, 2.0),
  (27, 2.25),
  (27, 2.5),
  (27, 2.75),
  (28, 2.0),
  (28, 2.25),
  (28, 2.5),
  (28, 2.75),
  (29, 2.0),
  (29, 2.25),
  (29, 2.5),
  (29, 2.75),
  (30, 2.0),
  (30, 2.25),
  (30, 2.5),
  (30, 2.75),
  (31, 2.0),
  (31, 2.25),
  (31, 2.5),
  (31, 2.75),
  (32, 2.0),
  (32, 2.25),
  (32, 2.5),
  (32, 2.75),
  (33, 2.0),
  (33, 2.25),
  (33, 2.5),
  (33, 2.75),
  (34, 2.0),
  (34, 2.25),
  (34, 2.5),
  (34, 2.75)],
 [(11, 25, 9),
  (11, 25, 10),
  (11, 26, 9),
  (11, 26, 10),
  (12, 25, 9),
  (12, 25, 10),
  (12, 26, 9),
  (12, 26, 10),
  (13, 25, 9),
  (13, 25, 10),
  (13, 26, 9),
  (13, 26, 10)],
 [(20, 50, 0.0),
  (20, 50, 0.002),
  (20, 50, 0.004),
  (20, 50, 0.006),
  (20, 50, 0.008)],
 [(13, 70, 25),
  (13, 70, 30),
  (13, 75, 25),
  (13, 75, 30),
  (14, 70, 25),
  (14, 70, 30),
  (14, 75, 25),
  (14, 75, 30),
  (15, 70, 25),
  (15, 70, 30),
  (15, 75, 25),
  (15, 75, 30)],
 [(20, 2.0),
  (20, 2.25),
  (20, 2.5),
  (20, 2.75),
  (21, 2.0),
  (21, 2.25),
  (21, 2.5),
  (21, 2.75),
  (22, 2.0),
  (22, 2.25),
  (22, 2.5),
  (22, 2.75),
  (23, 2.0),
  (23, 2.25),
  (23, 2.5),
  (23, 2.75),
  (24, 2.0),
  (24, 2.25),
  (24, 2.5),
  (24, 2.75),
  (25, 2.0),
  (25, 2.25),
  (25, 2.5),
  (25, 2.75),
  (26, 2.0),
  (26, 2.25),
  (26, 2.5),
  (26, 2.75),
  (27, 2.0),
  (27, 2.25),
  (27, 2.5),
  (27, 2.75),
  (28, 2.0),
  (28, 2.25),
  (28, 2.5),
  (28, 2.75),
  (29, 2.0),
  (29, 2.25),
  (29, 2.5),
  (29, 2.75),
  (30, 2.0),
  (30, 2.25),
  (30, 2.5),
  (30, 2.75),
  (31, 2.0),
  (31, 2.25),
  (31, 2.5),
  (31, 2.75),
  (32, 2.0),
  (32, 2.25),
  (32, 2.5),
  (32, 2.75),
  (33, 2.0),
  (33, 2.25),
  (33, 2.5),
  (33, 2.75),
  (34, 2.0),
  (34, 2.25),
  (34, 2.5),
  (34, 2.75)],
 [(13, 70, 25),
  (13, 70, 30),
  (13, 75, 25),
  (13, 75, 30),
  (14, 70, 25),
  (14, 70, 30),
  (14, 75, 25),
  (14, 75, 30),
  (15, 70, 25),
  (15, 70, 30),
  (15, 75, 25),
  (15, 75, 30)],
 [(11, 25, 9),
  (11, 25, 10),
  (11, 26, 9),
  (11, 26, 10),
  (12, 25, 9),
  (12, 25, 10),
  (12, 26, 9),
  (12, 26, 10),
  (13, 25, 9),
  (13, 25, 10),
  (13, 26, 9),
  (13, 26, 10)],
 [(13, 70, 25),
  (13, 70, 30),
  (13, 75, 25),
  (13, 75, 30),
  (14, 70, 25),
  (14, 70, 30),
  (14, 75, 25),
  (14, 75, 30),
  (15, 70, 25),
  (15, 70, 30),
  (15, 75, 25),
  (15, 75, 30)],
 [(20, 50, 0.0),
  (20, 50, 0.002),
  (20, 50, 0.004),
  (20, 50, 0.006),
  (20, 50, 0.008)],
 [(20, 2.0),
  (20, 2.25),
  (20, 2.5),
  (20, 2.75),
  (21, 2.0),
  (21, 2.25),
  (21, 2.5),
  (21, 2.75),
  (22, 2.0),
  (22, 2.25),
  (22, 2.5),
  (22, 2.75),
  (23, 2.0),
  (23, 2.25),
  (23, 2.5),
  (23, 2.75),
  (24, 2.0),
  (24, 2.25),
  (24, 2.5),
  (24, 2.75),
  (25, 2.0),
  (25, 2.25),
  (25, 2.5),
  (25, 2.75),
  (26, 2.0),
  (26, 2.25),
  (26, 2.5),
  (26, 2.75),
  (27, 2.0),
  (27, 2.25),
  (27, 2.5),
  (27, 2.75),
  (28, 2.0),
  (28, 2.25),
  (28, 2.5),
  (28, 2.75),
  (29, 2.0),
  (29, 2.25),
  (29, 2.5),
  (29, 2.75),
  (30, 2.0),
  (30, 2.25),
  (30, 2.5),
  (30, 2.75),
  (31, 2.0),
  (31, 2.25),
  (31, 2.5),
  (31, 2.75),
  (32, 2.0),
  (32, 2.25),
  (32, 2.5),
  (32, 2.75),
  (33, 2.0),
  (33, 2.25),
  (33, 2.5),
  (33, 2.75),
  (34, 2.0),
  (34, 2.25),
  (34, 2.5),
  (34, 2.75)],
 [(11, 25, 9),
  (11, 25, 10),
  (11, 26, 9),
  (11, 26, 10),
  (12, 25, 9),
  (12, 25, 10),
  (12, 26, 9),
  (12, 26, 10),
  (13, 25, 9),
  (13, 25, 10),
  (13, 26, 9),
  (13, 26, 10)],
 [(20, 2.0),
  (20, 2.25),
  (20, 2.5),
  (20, 2.75),
  (21, 2.0),
  (21, 2.25),
  (21, 2.5),
  (21, 2.75),
  (22, 2.0),
  (22, 2.25),
  (22, 2.5),
  (22, 2.75),
  (23, 2.0),
  (23, 2.25),
  (23, 2.5),
  (23, 2.75),
  (24, 2.0),
  (24, 2.25),
  (24, 2.5),
  (24, 2.75),
  (25, 2.0),
  (25, 2.25),
  (25, 2.5),
  (25, 2.75),
  (26, 2.0),
  (26, 2.25),
  (26, 2.5),
  (26, 2.75),
  (27, 2.0),
  (27, 2.25),
  (27, 2.5),
  (27, 2.75),
  (28, 2.0),
  (28, 2.25),
  (28, 2.5),
  (28, 2.75),
  (29, 2.0),
  (29, 2.25),
  (29, 2.5),
  (29, 2.75),
  (30, 2.0),
  (30, 2.25),
  (30, 2.5),
  (30, 2.75),
  (31, 2.0),
  (31, 2.25),
  (31, 2.5),
  (31, 2.75),
  (32, 2.0),
  (32, 2.25),
  (32, 2.5),
  (32, 2.75),
  (33, 2.0),
  (33, 2.25),
  (33, 2.5),
  (33, 2.75),
  (34, 2.0),
  (34, 2.25),
  (34, 2.5),
  (34, 2.75)],
 [(20, 50, 0.0),
  (20, 50, 0.002),
  (20, 50, 0.004),
  (20, 50, 0.006),
  (20, 50, 0.008)],
 [(11, 25, 9),
  (11, 25, 10),
  (11, 26, 9),
  (11, 26, 10),
  (12, 25, 9),
  (12, 25, 10),
  (12, 26, 9),
  (12, 26, 10),
  (13, 25, 9),
  (13, 25, 10),
  (13, 26, 9),
  (13, 26, 10)],
 [(20, 50, 0.0),
  (20, 50, 0.002),
  (20, 50, 0.004),
  (20, 50, 0.006),
  (20, 50, 0.008)],
 [(13, 70, 25),
  (13, 70, 30),
  (13, 75, 25),
  (13, 75, 30),
  (14, 70, 25),
  (14, 70, 30),
  (14, 75, 25),
  (14, 75, 30),
  (15, 70, 25),
  (15, 70, 30),
  (15, 75, 25),
  (15, 75, 30)],
 [(20, 2.0),
  (20, 2.25),
  (20, 2.5),
  (20, 2.75),
  (21, 2.0),
  (21, 2.25),
  (21, 2.5),
  (21, 2.75),
  (22, 2.0),
  (22, 2.25),
  (22, 2.5),
  (22, 2.75),
  (23, 2.0),
  (23, 2.25),
  (23, 2.5),
  (23, 2.75),
  (24, 2.0),
  (24, 2.25),
  (24, 2.5),
  (24, 2.75),
  (25, 2.0),
  (25, 2.25),
  (25, 2.5),
  (25, 2.75),
  (26, 2.0),
  (26, 2.25),
  (26, 2.5),
  (26, 2.75),
  (27, 2.0),
  (27, 2.25),
  (27, 2.5),
  (27, 2.75),
  (28, 2.0),
  (28, 2.25),
  (28, 2.5),
  (28, 2.75),
  (29, 2.0),
  (29, 2.25),
  (29, 2.5),
  (29, 2.75),
  (30, 2.0),
  (30, 2.25),
  (30, 2.5),
  (30, 2.75),
  (31, 2.0),
  (31, 2.25),
  (31, 2.5),
  (31, 2.75),
  (32, 2.0),
  (32, 2.25),
  (32, 2.5),
  (32, 2.75),
  (33, 2.0),
  (33, 2.25),
  (33, 2.5),
  (33, 2.75),
  (34, 2.0),
  (34, 2.25),
  (34, 2.5),
  (34, 2.75)],
 [(11, 25, 9),
  (11, 25, 10),
  (11, 26, 9),
  (11, 26, 10),
  (12, 25, 9),
  (12, 25, 10),
  (12, 26, 9),
  (12, 26, 10),
  (13, 25, 9),
  (13, 25, 10),
  (13, 26, 9),
  (13, 26, 10)],
 [(13, 70, 25),
  (13, 70, 30),
  (13, 75, 25),
  (13, 75, 30),
  (14, 70, 25),
  (14, 70, 30),
  (14, 75, 25),
  (14, 75, 30),
  (15, 70, 25),
  (15, 70, 30),
  (15, 75, 25),
  (15, 75, 30)],
 [(20, 2.0),
  (20, 2.25),
  (20, 2.5),
  (20, 2.75),
  (21, 2.0),
  (21, 2.25),
  (21, 2.5),
  (21, 2.75),
  (22, 2.0),
  (22, 2.25),
  (22, 2.5),
  (22, 2.75),
  (23, 2.0),
  (23, 2.25),
  (23, 2.5),
  (23, 2.75),
  (24, 2.0),
  (24, 2.25),
  (24, 2.5),
  (24, 2.75),
  (25, 2.0),
  (25, 2.25),
  (25, 2.5),
  (25, 2.75),
  (26, 2.0),
  (26, 2.25),
  (26, 2.5),
  (26, 2.75),
  (27, 2.0),
  (27, 2.25),
  (27, 2.5),
  (27, 2.75),
  (28, 2.0),
  (28, 2.25),
  (28, 2.5),
  (28, 2.75),
  (29, 2.0),
  (29, 2.25),
  (29, 2.5),
  (29, 2.75),
  (30, 2.0),
  (30, 2.25),
  (30, 2.5),
  (30, 2.75),
  (31, 2.0),
  (31, 2.25),
  (31, 2.5),
  (31, 2.75),
  (32, 2.0),
  (32, 2.25),
  (32, 2.5),
  (32, 2.75),
  (33, 2.0),
  (33, 2.25),
  (33, 2.5),
  (33, 2.75),
  (34, 2.0),
  (34, 2.25),
  (34, 2.5),
  (34, 2.75)],
 [(20, 50, 0.0),
  (20, 50, 0.002),
  (20, 50, 0.004),
  (20, 50, 0.006),
  (20, 50, 0.008)],
 [(13, 70, 25),
  (13, 70, 30),
  (13, 75, 25),
  (13, 75, 30),
  (14, 70, 25),
  (14, 70, 30),
  (14, 75, 25),
  (14, 75, 30),
  (15, 70, 25),
  (15, 70, 30),
  (15, 75, 25),
  (15, 75, 30)],
 [(11, 25, 9),
  (11, 25, 10),
  (11, 26, 9),
  (11, 26, 10),
  (12, 25, 9),
  (12, 25, 10),
  (12, 26, 9),
  (12, 26, 10),
  (13, 25, 9),
  (13, 25, 10),
  (13, 26, 9),
  (13, 26, 10)],
 [(20, 50, 0.0),
  (20, 50, 0.002),
  (20, 50, 0.004),
  (20, 50, 0.006),
  (20, 50, 0.008)],
 [(20, 2.0),
  (20, 2.25),
  (20, 2.5),
  (20, 2.75),
  (21, 2.0),
  (21, 2.25),
  (21, 2.5),
  (21, 2.75),
  (22, 2.0),
  (22, 2.25),
  (22, 2.5),
  (22, 2.75),
  (23, 2.0),
  (23, 2.25),
  (23, 2.5),
  (23, 2.75),
  (24, 2.0),
  (24, 2.25),
  (24, 2.5),
  (24, 2.75),
  (25, 2.0),
  (25, 2.25),
  (25, 2.5),
  (25, 2.75),
  (26, 2.0),
  (26, 2.25),
  (26, 2.5),
  (26, 2.75),
  (27, 2.0),
  (27, 2.25),
  (27, 2.5),
  (27, 2.75),
  (28, 2.0),
  (28, 2.25),
  (28, 2.5),
  (28, 2.75),
  (29, 2.0),
  (29, 2.25),
  (29, 2.5),
  (29, 2.75),
  (30, 2.0),
  (30, 2.25),
  (30, 2.5),
  (30, 2.75),
  (31, 2.0),
  (31, 2.25),
  (31, 2.5),
  (31, 2.75),
  (32, 2.0),
  (32, 2.25),
  (32, 2.5),
  (32, 2.75),
  (33, 2.0),
  (33, 2.25),
  (33, 2.5),
  (33, 2.75),
  (34, 2.0),
  (34, 2.25),
  (34, 2.5),
  (34, 2.75)],
 [(11, 25, 9),
  (11, 25, 10),
  (11, 26, 9),
  (11, 26, 10),
  (12, 25, 9),
  (12, 25, 10),
  (12, 26, 9),
  (12, 26, 10),
  (13, 25, 9),
  (13, 25, 10),
  (13, 26, 9),
  (13, 26, 10)],
 [(20, 50, 0.0),
  (20, 50, 0.002),
  (20, 50, 0.004),
  (20, 50, 0.006),
  (20, 50, 0.008)],
 [(13, 70, 25),
  (13, 70, 30),
  (13, 75, 25),
  (13, 75, 30),
  (14, 70, 25),
  (14, 70, 30),
  (14, 75, 25),
  (14, 75, 30),
  (15, 70, 25),
  (15, 70, 30),
  (15, 75, 25),
  (15, 75, 30)],
 [(20, 2.0),
  (20, 2.25),
  (20, 2.5),
  (20, 2.75),
  (21, 2.0),
  (21, 2.25),
  (21, 2.5),
  (21, 2.75),
  (22, 2.0),
  (22, 2.25),
  (22, 2.5),
  (22, 2.75),
  (23, 2.0),
  (23, 2.25),
  (23, 2.5),
  (23, 2.75),
  (24, 2.0),
  (24, 2.25),
  (24, 2.5),
  (24, 2.75),
  (25, 2.0),
  (25, 2.25),
  (25, 2.5),
  (25, 2.75),
  (26, 2.0),
  (26, 2.25),
  (26, 2.5),
  (26, 2.75),
  (27, 2.0),
  (27, 2.25),
  (27, 2.5),
  (27, 2.75),
  (28, 2.0),
  (28, 2.25),
  (28, 2.5),
  (28, 2.75),
  (29, 2.0),
  (29, 2.25),
  (29, 2.5),
  (29, 2.75),
  (30, 2.0),
  (30, 2.25),
  (30, 2.5),
  (30, 2.75),
  (31, 2.0),
  (31, 2.25),
  (31, 2.5),
  (31, 2.75),
  (32, 2.0),
  (32, 2.25),
  (32, 2.5),
  (32, 2.75),
  (33, 2.0),
  (33, 2.25),
  (33, 2.5),
  (33, 2.75),
  (34, 2.0),
  (34, 2.25),
  (34, 2.5),
  (34, 2.75)],
 [(11, 25, 9),
  (11, 25, 10),
  (11, 26, 9),
  (11, 26, 10),
  (12, 25, 9),
  (12, 25, 10),
  (12, 26, 9),
  (12, 26, 10),
  (13, 25, 9),
  (13, 25, 10),
  (13, 26, 9),
  (13, 26, 10)],
 [(20, 50, 0.0),
  (20, 50, 0.002),
  (20, 50, 0.004),
  (20, 50, 0.006),
  (20, 50, 0.008)]]
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: CypherX

68414808

Date: 2021-07-16 21:21:39
Score: 5
Natty:
Report link

= [387.02, 1899.68, 2485.55, 1167.79, 296.91, 937.42, 1293.7, 267.81, 540.25, 1112.86, 1249.76, 1655.71, 2413.3, 2691.82]

y = [956.05, 803.57, 632.88, 713.02, 1569.97, 1141.56, 960.69, 423.37, 317.17, 345.85, 430.96, 657.27, 397.27, 842.85]

result = [[x[i],y[i]] for i in range(len(x)-1)]

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: gesling

68410856

Date: 2021-07-16 15:40:23
Score: 5
Natty:
Report link

This code does produce the output you want. What makes you say it isn't correct?

>>> a1
array([[    1,     9,    25,    49,    81,   121,   169,   225,   289,
          361],
       [  441,   529,   625,   729,   841,   961,  1089,  1225,  1369,
         1521],
       [ 1681,  1849,  2025,  2209,  2401,  2601,  2809,  3025,  3249,
         3481],
       [ 3721,  3969,  4225,  4489,  4761,  5041,  5329,  5625,  5929,
         6241],
       [ 6561,  6889,  7225,  7569,  7921,  8281,  8649,  9025,  9409,
         9801],
       [10201, 10609, 11025, 11449, 11881, 12321, 12769, 13225, 13689,
        14161],
       [14641, 15129, 15625, 16129, 16641, 17161, 17689, 18225, 18769,
        19321],
       [19881, 20449, 21025, 21609, 22201, 22801, 23409, 24025, 24649,
        25281],
       [25921, 26569, 27225, 27889, 28561, 29241, 29929, 30625, 31329,
        32041],
       [32761, 33489, 34225, 34969, 35721, 36481, 37249, 38025, 38809,
        39601]])
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Ends in question mark (2):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Poorna Kumar

68403366

Date: 2021-07-16 05:23:54
Score: 7.5
Natty: 6
Report link

真尼玛牛逼,牛逼到极致了,我已经不好形容了,简直厉害。太牛逼了

Reasons:
  • Low length (2):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: user16459939

68383663

Date: 2021-07-14 19:56:50
Score: 3.5
Natty:
Report link
print(pow(256,256))  '''output - 21095088152386448283120630877367300996091750197750389652106796057638384067568276792218642619756161838094338476170470581645852036305042887575891541065808607552399123930385521914333389668342420684974786564569494856176035326322058077805659331026192708460314150258592864177116725943603718461857357598351152301645904403697613233287231227125684710820209725157101726931323469678542580656697935045997268352998638215525166389437335543602135433229604645318478604952148193555853611059596230656'''
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Shantanu

68376566

Date: 2021-07-14 11:49:30
Score: 6.5
Natty: 6
Report link

кароче тут такое дело сорян но я хз шо делать

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: ПРАГРАММИСТ

68376405

Date: 2021-07-14 11:36:54
Score: 5.5
Natty:
Report link

Короче, я не знаю, почему никто не ответил на мой вопрос, ведь он проще пареной репы: сначала надо было создать пустой конструктор, а потом наполнять объект с помощью сеттеров. Если туда вставить всё, включая ID, объект не вставится из-за конфликта

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: sedub01

68375327

Date: 2021-07-14 10:24:30
Score: 8.5
Natty:
Report link

yes...........................................................................

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): ...........................................................................
  • Low entropy (1):
  • Low reputation (1):
Posted by: karthick

68354542

Date: 2021-07-12 23:43:01
Score: 2.5
Natty:
Report link

Here is something working:

@eval begin                                                                                                                                                      
    function looped_eval2($(args_typed...))                                                                                                                                                                                                                                                                                       
    result = similar($big_expr_array, Vector{Float64})                                                                                                           
    result .= [[]]                                                                                                                                               
    $( (quote                                                                                                                                                                          
            # i = row, j = vector, k = specific expression                                                                                                 
            push!(result[$i, $j], $(expr))                                                                                                                           
        end                                                                                                                                                                                                                                                                                                                       
        for i in 1:size(big_expr_array, 1)                                                                                                                           
        for j in 1:size(big_expr_array, 2)                                                                                                                           
        for expr in big_expr_array[i, j]                                                                                                                                  
        )...                                                                                                                                                                                    
        )                                                                                                                                                           
    result                                                                                                                                                   
    end                                                                                                                                                      
end
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low entropy (1):
Posted by: pLOPeGG

68351734

Date: 2021-07-12 18:43:12
Score: 0.5
Natty:
Report link

Using map2

library(purrr)
map2(l1, l2, ~ .x[, -1] * .y[,-1])
[[1]]
     [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9]
[1,]  129  225  329  441  561  689  825  969 1121
[2,]  176  276  384  500  624  756  896 1044 1200

[[2]]
     [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9]
[1,] 1449 1625 1809 2001 2201 2409 2625 2849 3081
[2,] 1536 1716 1904 2100 2304 2516 2736 2964 3200
Reasons:
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-2):
Posted by: akrun

68348494

Date: 2021-07-12 14:53:29
Score: 1.5
Natty:
Report link

You can use pandas.Grouper to group by month, value_counts to count all occurrences of each item in sample.purpose.label, and unstack to reshape

df = pd.read_csv('2019.csv')
df['sample.sampleDateTime'] = pd.to_datetime(df['sample.sampleDateTime'])
df.set_index('sample.sampleDateTime').groupby(pd.Grouper(freq='M'))['sample.purpose.label'].value_counts().unstack(level=1)

output:

sample.purpose.label   COMPLIANCE AUDIT (PERMIT)  COMPLIANCE FORMAL (PERMIT)  ENVIRONMENTAL MONITORING STATUTORY (EU DIRECTIVES)  IPPC/IPC MONITORING (AGENCY AUDIT - PERMIT)  IPPC/IPC MONITORING (AGENCY INVESTIGATION)  IPPC/IPC MONITORING (FORMAL SAMPLE)  MONITORING  (NATIONAL AGENCY POLICY)  MONITORING  (UK GOVT POLICY - NOT GQA OR RE)  PLANNED FORMAL NON-STATUTORY (PERMIT/ENV MON)  PLANNED INVESTIGATION (LOCAL MONITORING)  PLANNED INVESTIGATION (NATIONAL AGENCY POLICY)  STATUTORY FAILURES (FOLLOW UPS AT DESIGNATED POINTS)  STATUTORY FAILURES (FOLLOW UPS AT NON-DESIGNATED POINTS)  UNPLANNED REACTIVE MONITORING (POLLUTION INCIDENTS)  UNPLANNED REACTIVE MONITORING FORMAL (POLLUTION INCIDENTS)  WASTE MONITORING (AGENCY AUDIT - PERMIT)  WASTE MONITORING (AGENCY INVESTIGATION)  WASTE MONITORING (FORMAL SAMPLE)  WATER QUALITY OPERATOR SELF MONITORING COMPLIANCE DATA  WATER QUALITY UWWTD MONITORING DATA
sample.sampleDateTime                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         
2019-01-31                                5219.0                        44.0                                             47360.0                                          NaN                                       887.0                                  NaN                                2498.0                                       10624.0                                            NaN                                    8534.0                                           823.0                                                2599.0                                                    7556.0                                               2787.0                                                      1491.0                                       NaN                                     12.0                               NaN                                                 11800.0                               8359.0
2019-02-28                                3971.0                        22.0                                             53000.0                                         38.0                                       536.0                                  NaN                                2537.0                                       10053.0                                            NaN                                   10688.0                                           702.0                                                3023.0                                                    8295.0                                               2930.0                                                      1151.0                                       NaN                                    534.0                             624.0                                                 11781.0                               5443.0
2019-03-31                                3838.0                        52.0                                             42524.0                                         31.0                                       689.0                                 18.0                                5548.0                                        9273.0                                            9.0                                    9630.0                                           786.0                                                2084.0                                                    5995.0                                               2792.0                                                       734.0                                       NaN                                    415.0                             443.0                                                 12275.0                               5672.0
2019-04-30                                3865.0                        34.0                                             73070.0                                         24.0                                        55.0                                  NaN                                3450.0                                        6665.0                                            NaN                                    8202.0                                          7073.0                                                1261.0                                                    4827.0                                               2225.0                                                      1144.0                                       NaN                                   2175.0                               NaN                                                 12168.0                               5409.0
2019-05-31                                3695.0                        44.0                                             96911.0                                         27.0                                        58.0                                  NaN                                3053.0                                        7006.0                                            NaN                                    7663.0                                          9299.0                                                1356.0                                                    4665.0                                               2293.0                                                      1296.0                                       NaN                                    194.0                             188.0                                                 11982.0                               5934.0
2019-06-30                                3029.0                        36.0                                             83428.0                                         13.0                                         8.0                                  NaN                                5284.0                                        5362.0                                           24.0                                   10340.0                                          9402.0                                                2344.0                                                    5318.0                                               2299.0                                                      1217.0                                       NaN                                    278.0                              14.0                                                 12109.0                               5643.0
2019-07-31                                4385.0                        62.0                                            100697.0                                         24.0                                         NaN                                  NaN                                6574.0                                       11328.0                                            NaN                                    7820.0                                         10448.0                                                1551.0                                                    4539.0                                               3536.0                                                      1647.0                                       NaN                                   1278.0                             535.0                                                 13413.0                               5858.0
2019-08-31                                3196.0                        38.0                                             85826.0                                         38.0                                        15.0                                  NaN                                4018.0                                        6266.0                                            NaN                                    9474.0                                         10375.0                                                2253.0                                                    5989.0                                               2304.0                                                      1023.0                                     240.0                                     95.0                             186.0                                                 12303.0                               5514.0
2019-09-30                                3519.0                         8.0                                             88239.0                                         17.0                                       244.0                                  NaN                                7008.0                                        7007.0                                            NaN                                    8234.0                                         10809.0                                                1702.0                                                    4151.0                                               1774.0                                                      1345.0                                       NaN                                      NaN                            2422.0                                                 12895.0                               5617.0
2019-10-31                                4569.0                        28.0                                             91347.0                                         24.0                                         NaN                                  NaN                                7416.0                                        7214.0                                            NaN                                   16760.0                                         12467.0                                                1152.0                                                    3567.0                                               1690.0                                                      1078.0                                     120.0                                    595.0                             373.0                                                 13023.0                               5975.0
2019-11-30                                4290.0                         8.0                                             76318.0                                         38.0                                         NaN                                 30.0                                8172.0                                        6024.0                                            NaN                                    5315.0                                         11514.0                                                  31.0                                                    1352.0                                               1540.0                                                      1036.0                                       NaN                                   1255.0                             360.0                                                 13196.0                               6042.0
2019-12-31                                3356.0                        17.0                                             71900.0                                         24.0                                        14.0                                  NaN                                5331.0                                        6138.0                                            NaN                                    6520.0                                         10673.0                                                 849.0                                                    1930.0                                               1725.0                                                      1010.0                                       NaN                                   2894.0                             895.0                                                  9425.0                               4329.0
Reasons:
  • Whitelisted phrase (-1.5): You can use
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low entropy (1):
  • Low reputation (0.5):
Posted by: mozway

68348116

Date: 2021-07-12 14:26:01
Score: 1
Natty:
Report link
keep = colnames(myData) %in% rownames(myData)
myData[keep, keep]
         0818402  0818403  0818404  0818701  0818702  0818703  0818706
0818404 8982.463 11995.11 36507.17  615.594  346.328  447.489   710.92
0818701  213.145  239.574  667.364 50675.95  16698.7 6186.076 12028.52
0818702  160.983  108.902  267.145 17014.93 8741.939 8226.877 2611.744
0818703  221.232  180.345  396.153 6146.109 8238.827 10457.78 2222.986
0818706  159.725  186.178  703.365 11449.73 2516.798 1841.649  6597.93
0818707   43.183   32.864  102.109 7992.958   3632.7 1459.469 1841.177
08194     40.326   15.903   56.918  156.053   31.708  114.956  111.518
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: user438383

68329083

Date: 2021-07-10 16:31:52
Score: 1
Natty:
Report link
s = '''00:00 - вступление Сергея Немчинского
01:26 - профессия это не на всю жизнь
04:45 - важность выбора языка программирования
07:48 - системы управления контролем версий
09:51 - поисковик
12:10 - больше практики
13:12 - и больше отдыха
14:38 - программирование это больше чем синтаксис
17:15 - невозможно выучить все
10:19:38 - разберитесь в себе и делайте то, что нравится :)'''

import re

re.findall(r'^\d[\d:]+', s, re.MULTILINE)

# ['00:00',
#  '01:26',
#  '04:45',
#  '07:48',
#  '09:51',
#  '12:10',
#  '13:12',
#  '14:38',
#  '17:15',
#  '10:19:38']

Description of the regex here

Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Epsi95

68328853

Date: 2021-07-10 16:05:54
Score: 7
Natty:
Report link

*https://stackoverflow.com/ *

*Good day *


Reasons:
  • Blacklisted phrase (1): stackoverflow
  • Blacklisted phrase (1): Good day
  • Low length (0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low entropy (1):
  • Low reputation (1):
Posted by: Jose Antonio Garcia Padilla

68321348

Date: 2021-07-09 19:35:16
Score: 8.5
Natty:
Report link

.......................................................................

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): .......................................................................
  • Low entropy (1):
  • Low reputation (1):
Posted by: anonymous

68299390

Date: 2021-07-08 11:01:56
Score: 4
Natty:
Report link
    "foo": {
                                
                                "type": "array",
                                "minItems": "1",
                                "items": {
                                    
                                    "title": "items",
                                    "type": "object",
                                    "required": [
                                        "hi",
                                        "ij"
                                    ],
                                    
                                    "properties": {
                                        "hi": {
                                            
                                            "title": "hi",
                                            
                                            "type": "string",
                                            
                                            "enum": [
                                                "foo1",
                                                "foo2",
                                                "
                                            ]
                                        },
                                        "ij": {
                                            "type": "string"
                                            
                                        }
                                    },  "allOf": [
                                            {
                                                "if": {
                                                    "properties": {
                                                        "hi": {
                                                            "enum": [
                                                                "foo",
                                                                "foo1"
                                                            ]
                                                        }
                                                    },
                                                    "required": [
                                                        "hi"
                                                    ]
                                                },
                                                "then": {
                                                    "properties": {
                                                        "ij": {
                                                            
                                                            "pattern": "^\\d*$"
                                                        }
                                                    }
                                                }
                                            }
]

                                }
                            }

the above logic is working thank for contributing

Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • Low entropy (1):
  • Low reputation (1):
Posted by: THEJES

68281773

Date: 2021-07-07 08:34:32
Score: 6.5
Natty:
Report link

Just use this! ⣿⣿⣿⣿⣿⣿⣿⣿⡿⠿⠛⠛⠛⢻⡻⠿⣿⣿⣿⣿⣿⣿⣿⣿ ⣿⣿⣿⣿⣿⣿⣟⣫⡾⠛⠛⠛⠛⠛⠛⠿⣾⣽⡻⣿⣿⣿⣿⣿ ⣿⣿⣿⣿⣿⡟⣼⠏⠀⠀⠀⠀⠀⠀⣀⣀⡀⣙⣿⣎⢿⣿⣿⣿ ⣿⣿⣿⣿⣿⢹⡟⠀⠀⠀⣰⡾⠟⠛⠛⠛⠛⠛⠛⠿⣮⡻⣿⣿ ⣿⡿⢟⣻⣟⣽⠇⠀⠀⠀⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⢿⡹⣿ ⠀⠀⠀⠀

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Filler text (0.5): ⣿⣿⣿⣿⣿⣿⣿⣿
  • Filler text (0): ⣿⣿⣿⣿⣿⣿⣿⣿
  • Filler text (0): ⠀⠀⠀⠀⠀⠀⠀⠀⠀
  • Low reputation (1):
Posted by: user16397019

68254222

Date: 2021-07-05 11:10:43
Score: 8.5
Natty:
Report link

......................................................

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): ......................................................
  • Low entropy (1):
  • Low reputation (1):
Posted by: Ann's

68253892

Date: 2021-07-05 10:47:07
Score: 1.5
Natty:
Report link

Your comparison is wrong, if the points are within the circle, it needs to be <= radius**2. Than your code works, also find below an optimized version using pandas, without a loop


import pandas as pd

def in_cycle(center_x, center_y, radius, x, y):
    return (x - center_x)**2 + (y - center_y)**2 <= radius**2


l = arr = [[-0.2384903,   0.28638432, -0.52100003], [-0.23179091,  0.28418559, -0.51700002], [-0.22692253,  0.28418559, -0.51700002], [-0.22046956,  0.28528494, -0.51899999], [-0.21518661,  0.28638432, -0.52100003], [-0.24017692,  0.28570513, -0.52200001], [-0.23345869,  0.28351582, -0.51800001], [-0.22813963,  0.2829685 , -0.51700002], [-0.22370311,  0.28351582, -0.51800001], [-0.21967019,  0.28461046, -0.51999998], [-0.21518661,  0.28515781, -0.52100003], [-0.20773969,  0.28844177, -0.52700001], [-0.24017692,  0.28447627, -0.52200001], [-0.23345869,  0.28229637, -0.51800001], [-0.22813963,  0.2817514 , -0.51700002], [-0.22370311,  0.28229637, -0.51800001], [-0.21967019,  0.2833863 , -0.51999998], [-0.21518661,  0.2839313 , -0.52100003], [-0.21025782,  0.2855662 , -0.52399999], [-0.20728272,  0.28829107, -0.52899998], [-0.24017692,  0.2832474 , -0.52200001], [-0.23345869,  0.28107692, -0.51800001], [-0.22813963,  0.28053431, -0.51700002], [-0.22370311,  0.28107692, -0.51800001], [-0.21967019,  0.28216215, -0.51999998], [-0.21559964,  0.2832474 , -0.52200001], [-0.21149139,  0.28433263, -0.52399999], [-0.20813387,  0.28650311, -0.528     ], [-0.2384903 ,  0.28147828, -0.52100003], [-0.23223924,  0.27985747, -0.51800001], [-0.22736145,  0.27985747, -0.51800001], [-0.22248366,  0.27985747, -0.51800001], [-0.21886614,  0.28147828, -0.52100003], [-0.21437077,  0.28201854, -0.52200001], [-0.21065907,  0.28363932, -0.52499998], [-0.20806641,  0.28688093, -0.53100002], [-0.23513117,  0.27917593, -0.51899999], [-0.22980034,  0.27863803, -0.51800001], [-0.22492255,  0.27863803, -0.51800001], [-0.22089435,  0.27971384, -0.51999998], [-0.2168285 ,  0.28078968, -0.52200001], [-0.21272496,  0.28186548, -0.52399999], [-0.20937686,  0.28401713, -0.528     ], [-0.23726379,  0.27902526, -0.52100003], [-0.23101979,  0.27741858, -0.51800001], [-0.22657856,  0.27795413, -0.51899999], [-0.2221185 ,  0.27848968, -0.51999998], [-0.21805736,  0.27956081, -0.52200001], [-0.21395853,  0.28063191, -0.52399999], [-0.21061985,  0.28277415, -0.528     ], [-0.23986355,  0.27939834, -0.52399999], [-0.2331359 ,  0.27726552, -0.51999998], [-0.22780037,  0.27673233, -0.51899999], [-0.22334266,  0.27726552, -0.51999998], [-0.21928623,  0.27833195, -0.52200001], [-0.2151921 ,  0.27939834, -0.52399999], [-0.21186284,  0.28153116, -0.528     ], [-0.24821244,  0.28347325, -0.53399998], [-0.23649032,  0.27710308, -0.52200001], [-0.23068759,  0.27604137, -0.51999998], [-0.22579097,  0.27604137, -0.51999998], [-0.22131916,  0.27657224, -0.52100003], [-0.21765925,  0.27816477, -0.52399999], [-0.21394286,  0.27975733, -0.52700001], [-0.2113596 ,  0.28294241, -0.53299999], [-0.23908537,  0.27745968, -0.52499998], [-0.23235775,  0.27534573, -0.52100003], [-0.22701513,  0.27481721, -0.51999998], [-0.22254567,  0.27534573, -0.52100003], [-0.21889282,  0.2769312 , -0.52399999], [-0.21518349,  0.27851669, -0.52700001], [-0.21221546,  0.28115916, -0.53200001], [-0.24215232,  0.27832832, -0.52899998], [-0.23448093,  0.27517149, -0.523     ], [-0.22867822,  0.27411922, -0.52100003], [-0.22420168,  0.27464536, -0.52200001], [-0.22012639,  0.27569762, -0.52399999], [-0.2168348 ,  0.27780219, -0.528     ], [-0.21346787,  0.27990676, -0.53200001], [-0.24090698,  0.27708298, -0.52899998], [-0.23369569,  0.27446405, -0.52399999], [-0.22788828,  0.27341649, -0.52200001], [-0.22382711,  0.27446405, -0.52399999], [-0.2197283 ,  0.27551164, -0.52600002], [-0.21640843,  0.27760676, -0.52999997], [-0.24398335,  0.27792337, -0.53299999], [-0.23582595,  0.27427336, -0.52600002], [-0.22955606,  0.27270905, -0.523     ], [-0.22506068,  0.27323048, -0.52399999], [-0.22180675,  0.27531621, -0.528     ], [-0.21806682,  0.27688052, -0.53100002], [-0.24272859,  0.27666861, -0.53299999], [-0.23503365,  0.27355415, -0.52700001], [-0.2287614 ,  0.27199691, -0.52399999], [-0.22468143,  0.27303508, -0.52600002], [-0.22139922,  0.27511137, -0.52999997], [-0.21804171,  0.27718768, -0.53399998], [-0.23592561,  0.27334695, -0.52899998], [-0.22963455,  0.2717968 , -0.52600002], [-0.22553572,  0.27283023, -0.528     ], [-0.2222347 ,  0.27489713, -0.53200001], [-0.23681759,  0.27313037, -0.53100002], [-0.23050767,  0.27158725, -0.528     ], [-0.22639001,  0.27261597, -0.52999997], [-0.22307016,  0.27467346, -0.53399998], [-0.23181739,  0.27188031, -0.53100002], [-0.22767147,  0.27290433, -0.53299999], [-0.23143575,  0.27164957, -0.53299999], [-0.15836202,  0.20225762, -0.53200001], [-0.16369571,  0.19987172, -0.52899998], [-0.15781427,  0.19873824, -0.52600002], [-0.15286115,  0.19873824, -0.52600002], [-0.14987638,  0.20138304, -0.53299999], [-0.15937662,  0.19637353, -0.523     ], [-0.15415643,  0.19599806, -0.52200001], [-0.15038459,  0.19749996, -0.52600002], [-0.16307028,  0.19514231, -0.523     ], [-0.15784303,  0.19476919, -0.52200001], [-0.15292757,  0.19476919, -0.52200001], [-0.14914631,  0.19626168, -0.52600002], [-0.1461121 ,  0.19887352, -0.53299999], [-0.16152962,  0.19354033, -0.52200001], [-0.15661416,  0.19354033, -0.52200001], [-0.15169871,  0.19354033, -0.52200001], [-0.14790803,  0.1950234 , -0.52600002], [-0.14431379,  0.19687723, -0.53100002], [-0.17176128,  0.19415353, -0.52700001], [-0.16553271,  0.19267987, -0.523     ], [-0.16030075,  0.19231147, -0.52200001], [-0.1553853 ,  0.19231147, -0.52200001], [-0.15046984,  0.19231147, -0.52200001], [-0.14639089,  0.19341669, -0.52499998], [-0.14306374,  0.19562718, -0.53100002], [-0.17019708,  0.19254684, -0.52600002], [-0.16430149,  0.19144866, -0.523     ], [-0.15876716,  0.19071655, -0.52100003], [-0.15415643,  0.1910826 , -0.52200001], [-0.14924098,  0.1910826 , -0.52200001], [-0.14487849,  0.19181471, -0.52399999], [-0.14154661,  0.19401105, -0.52999997], [-0.1689588 ,  0.19130856, -0.52600002], [-0.16275848,  0.18985374, -0.52200001], [-0.15754065,  0.18949004, -0.52100003], [-0.15263461,  0.18949004, -0.52100003], [-0.14801211,  0.18985374, -0.52200001], [-0.14364491,  0.19058114, -0.52399999], [-0.14029891,  0.19276336, -0.52999997], [-0.1689588 ,  0.19007028, -0.52600002], [-0.16307028,  0.18898622, -0.523     ], [-0.15784303,  0.18862487, -0.52200001], [-0.15292757,  0.18862487, -0.52200001], [-0.14801211,  0.18862487, -0.52200001], [-0.14364491,  0.18934756, -0.52399999], [-0.13976949,  0.19079297, -0.528     ], [-0.17365846,  0.18990897, -0.52899998], [-0.16708279,  0.18811399, -0.52399999], [-0.16152962,  0.18739601, -0.52200001], [-0.15661416,  0.18739601, -0.52200001], [-0.15169871,  0.18739601, -0.52200001], [-0.14678325,  0.18739601, -0.52200001], [-0.14241134,  0.18811399, -0.52399999], [-0.1385265 ,  0.18954998, -0.528     ], [-0.17523443,  0.18902027, -0.52999997], [-0.1689588 ,  0.18759372, -0.52600002], [-0.16307028,  0.18652378, -0.523     ], [-0.15784303,  0.18616715, -0.52200001], [-0.15292757,  0.18616715, -0.52200001], [-0.14801211,  0.18616715, -0.52200001], [-0.14364491,  0.18688042, -0.52399999], [-0.13924006,  0.18759372, -0.52600002], [-0.13607402,  0.1900902 , -0.5329999 ]]
df = pd.DataFrame(l, columns=["x","y", "z"])

radius = 3
center_x = 0
center_y = 0

df_in_radius = df[df.apply(lambda x: in_cycle(center_x,center_y,radius, x.x,x.y), axis=1)]
local_maximum = df_in_radius.loc[df_in_radius.z.idxmax() ]
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
Posted by: FloLie

68246761

Date: 2021-07-04 17:32:21
Score: 2
Natty:
Report link

using:

transposed_df.to_csv('parameter.csv', sep='\n')

in line 40

gives


0
1
2
3
4
5
6
7
8
9
parameter1
49.6
32.9
58.7
50.1
32.2
35.2
44.7
52.8
50.1
53.3
parameter2
"[229.33626371  31.41592654 135.0884841  282.74333882 125.66370614
 263.8937829    6.28318531  34.55751919 172.78759595 276.46015352]"
"[201.06192983   3.14159265  75.39822369  72.25663103 116.23892818
 204.20352248  50.26548246  65.97344573 194.77874452  50.26548246]"
"[ 91.10618695  75.39822369  65.97344573 298.45130209 279.60174617
 179.07078125 216.7698931  144.51326207 191.63715187 301.59289474]"
"[128.8052988   12.56637061 113.09733553  37.69911184 238.76104167
 150.79644737 307.87608005 279.60174617 292.16811678  12.56637061]"
"[ 59.69026042 113.09733553  25.13274123  65.97344573  34.55751919
 282.74333882  78.53981634 153.93804003   3.14159265 194.77874452]"
"[241.90263433 185.35396656  43.98229715  56.54866776 282.74333882
  69.11503838 100.53096491  50.26548246  34.55751919  40.8407045 ]"
"[188.49555922 172.78759595 270.17696821 219.91148575  62.83185307
  78.53981634 179.07078125 157.07963268  72.25663103   3.14159265]"
"[270.17696821 144.51326207 175.9291886   62.83185307  12.56637061
 106.81415022 235.61944902 179.07078125 279.60174617 191.63715187]"
"[103.67255757  81.68140899 248.18581963 122.52211349 210.48670779
 282.74333882 219.91148575  87.9645943   69.11503838 147.65485472]"
"[ 94.24777961 295.30970944  78.53981634 219.91148575  75.39822369
  65.97344573 163.36281799 219.91148575 175.9291886  285.88493148]"
parameter3
49.0
23.5
59.0
44.5
23.0
20.0
52.5
56.5
43.0
54.0

let us know if it is what you were looking for, I cannot really visualize from your question the desidered output

Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: pippo1980

68239959

Date: 2021-07-03 22:12:19
Score: 0.5
Natty:
Report link

Use

(?:[0-90-9]+[ⅠⅡⅢⅣⅥⅦⅧⅨⅪⅫⅤⅩⅬⅭⅮⅯA-Za-zA-z]+|[ⅠⅡⅢⅣⅥⅦⅧⅨⅪⅫⅤⅩⅬⅭⅮⅯA-Za-zA-z]+[0-90-9]+)[ⅠⅡⅢⅣⅥⅦⅧⅨⅪⅫⅤⅩⅬⅭⅮⅯA-Za-zA-z0-90-9]*(?!\p{L})(?<!mg(?=/kg)|mg(?=\/kg)|nm|nm|MHz|ppm|ppm|mmol|mmol|mL|mL|mol|mol|nM|nM|μL|v(?=\/v)|[gg])

See regex proof.

EXPLANATION

--------------------------------------------------------------------------------
  (?:                      group, but do not capture:
--------------------------------------------------------------------------------
    [0-90-9]+           any character of: '0' to '9' (1 or more times 
                           (matching the most  amount possible))
--------------------------------------------------------------------------------
    [ⅠⅡⅢⅣⅥⅦⅧⅨⅪⅫⅤⅩⅬⅭⅮⅯ       any Roman number or 'A' to 'Z', 'a' to 'z'
     A-Za-zA-z]+                   or 'A' to 'z'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    [ⅠⅡⅢⅣⅥⅦⅧⅨⅪⅫⅤⅩⅬⅭⅮⅯ       any Roman number or 'A' to 'Z', 'a' to 'z'
     A-Za-zA-z]+                   or 'A' to 'z'
--------------------------------------------------------------------------------
    [0-90-9]+              any character of: '0' to '9'
                             (1 or more times (matching the most amount possible))
--------------------------------------------------------------------------------
  )                        end of grouping
--------------------------------------------------------------------------------
  [ⅠⅡⅢⅣⅥⅦⅧⅨⅪⅫⅤ       any Roman number, or 'A' to 'Z', 'a' to 'z'
  ⅩⅬⅭⅮⅯA-Za-z             or 'A' to 'z'
  A-z0-90-9]*          
--------------------------------------------------------------------------------
  (?!                      look ahead to see if there is not:
--------------------------------------------------------------------------------
    \p{L}                    any Unicode letter character 
--------------------------------------------------------------------------------
  )                        end of look-ahead
--------------------------------------------------------------------------------
  (?<!                     look behind to see if there is not:
--------------------------------------------------------------------------------
    mg                    'mg'
--------------------------------------------------------------------------------
    (?=                      look ahead to see if there is:
--------------------------------------------------------------------------------
      /kg                      '/kg'
--------------------------------------------------------------------------------
    )                        end of look-ahead
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    mg                       'mg'
--------------------------------------------------------------------------------
    (?=                      look ahead to see if there is:
--------------------------------------------------------------------------------
      \/kg                       '/kg'
--------------------------------------------------------------------------------
    )                        end of look-ahead
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
   nm                     'nm'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    nm                       'nm'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    MHz                      'MHz'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    ppm                  'ppm'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    ppm                      'ppm'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    mmol                     'mmol'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    mmol                'mmol'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    mL                       'mL'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    mL                  'mL'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    mol                      'mol'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    mol                  'mol'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    nM                       'nM'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
   nM                      'nM'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    μL                  'μL'
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    v                        'v'
--------------------------------------------------------------------------------
    (?=                      look ahead to see if there is:
--------------------------------------------------------------------------------
      \/v                        '/v'
--------------------------------------------------------------------------------
    )                        end of look-ahead
--------------------------------------------------------------------------------
   |                        OR
--------------------------------------------------------------------------------
    [gg]                   any character of: 'g' or 'g'
--------------------------------------------------------------------------------
  )                        end of look-behind
Reasons:
  • Probably link only (1):
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-2):
Posted by: Ryszard Czech

68222603

Date: 2021-07-02 10:19:50
Score: 0.5
Natty:
Report link

Try append with list

> append(list(tmp), list(tmp1))
[[1]]
           [,1]       [,2]       [,3]
[1,] -1.6917740  2.2938118 -0.5994428
[2,] -0.8317474 -2.1021389  1.0077591
[3,] -0.6893888 -0.3864561  0.5299755

[[2]]
           [,1]       [,2]        [,3]
[1,]  0.6431510  1.6601869 -0.03001407
[2,] -0.8729105 -0.8919077  0.68717777
[3,]  0.4114760 -1.4556726 -1.52659021
[4,]  1.1093545  1.0937816  1.11888348
Reasons:
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-2):
Posted by: ThomasIsCoding

68217314

Date: 2021-07-01 22:54:55
Score: 4
Natty:
Report link

This is an example geojson : { "type": "FeatureCollection", "features": [ { "type": "Feature", "properties": {}, "geometry": { "type": "Polygon", "coordinates": [ [ [ 9.393310546875, 30.56226095049944 ], [ 6.591796875, 30.0405664305846 ], [ 6.459960937499999, 30.06909396443887 ], [ 5.712890625, 29.76437737516313 ], [ 5.745849609375, 28.488005204159457 ], [ 5.625, 28.110748760633534 ], [ 5.778808593749999, 27.449790329784214 ], [ 5.756835937499999, 27.078691552927534 ], [ 6.295166015625, 26.598351182358293 ], [ 6.295166015625, 26.519735305660795 ], [ 6.185302734375, 26.37218544169559 ], [ 6.163330078125, 26.27371402440643 ], [ 6.295166015625, 26.23430203240673 ], [ 6.35009765625, 26.15543796871355 ], [ 6.591796875, 25.55235365216549 ], [ 6.712646484375, 25.363882272740256 ], [ 6.844482421875, 25.12539261151203 ], [ 6.932373046875, 24.926294766395593 ], [ 7.020263671875, 24.806681353851964 ], [ 7.14111328125, 24.756808311192707 ], [ 7.261962890625, 24.746831298412058 ], [ 7.547607421875, 24.44714958973082 ], [ 7.509155273437499, 24.27701247166408 ], [ 7.536621093749999, 23.860721778614522 ], [ 7.7398681640625, 23.34225583513053 ], [ 7.66845703125, 23.276673210348186 ], [ 7.91015625, 23.089838367476705 ], [ 8.624267578125, 23.211058276488192 ], [ 9.184570312499998, 23.543845136505844 ], [ 9.20654296875, 23.563987128451217 ], [ 9.810791015625, 23.538809156294388 ], [ 9.8876953125, 23.51362636346272 ], [ 9.964599609375, 23.51362636346272 ], [ 10.0689697265625, 23.438049100368612 ], [ 10.1898193359375, 23.387640227334956 ], [ 10.272216796875, 23.33216830631147 ], [ 10.2392578125, 22.507482299898438 ], [ 12.0025634765625, 23.538809156294388 ], [ 11.6070556640625, 24.261989400796306 ], [ 11.414794921875, 24.196868919249656 ], [ 11.0467529296875, 24.43214670001101 ], [ 10.9368896484375, 24.5271348225978 ], [ 10.832519531249998, 24.56710835257599 ], [ 10.8050537109375, 24.53712939907993 ], [ 10.772094726562498, 24.52213723599524 ], [ 10.74462890625, 24.552119771544227 ], [ 10.70068359375, 24.57210414801684 ], [ 10.651245117187498, 24.57210414801684 ], [ 10.557861328125, 24.542126388899305 ], [ 10.447998046875, 24.53712939907993 ], [ 10.37109375, 24.53712939907993 ], [ 10.2777099609375, 24.59208533779722 ], [ 10.2227783203125, 24.632038149596895 ], [ 10.1788330078125, 24.751819904924858 ], [ 10.1129150390625, 24.831610355586918 ], [ 10.074462890625, 24.896402266558727 ], [ 10.0250244140625, 24.971119927578236 ], [ 10.0250244140625, 25.339061458818374 ], [ 9.404296875, 26.1899475672235 ], [ 9.459228515625, 26.27371402440643 ], [ 9.503173828125, 26.382027976025352 ], [ 9.876708984375, 26.52956523826758 ], [ 9.898681640625, 26.62781822639305 ], [ 9.909667968749998, 26.848578525873275 ], [ 9.854736328125, 26.95145308349826 ], [ 9.82177734375, 27.083582461484347 ], [ 9.8272705078125, 27.15692045688088 ], [ 9.7943115234375, 27.196014383173306 ], [ 9.7833251953125, 27.264395776495334 ], [ 9.7833251953125, 27.298570715261533 ], [ 9.788818359374998, 27.347373810080278 ], [ 9.7998046875, 27.391278222579277 ], [ 9.832763671875, 27.45466493898314 ], [ 9.84375, 27.51314343580719 ], [ 9.8602294921875, 27.547241546253268 ], [ 9.832763671875, 27.571590861376308 ], [ 9.8712158203125, 27.586197857692664 ], [ 9.926147460937498, 27.668934069896217 ], [ 9.95361328125, 27.843933386070514 ], [ 9.964599609375, 27.887639217136517 ], [ 9.8382568359375, 28.270520445825415 ], [ 9.9151611328125, 28.772474183943032 ], [ 9.766845703125, 29.42524498547202 ], [ 9.5416259765625, 29.897805610155874 ], [ 9.415283203125, 30.031055426540206 ], [ 9.393310546875, 30.164126343161097 ], [ 9.5526123046875, 30.221101852485987 ], [ 9.459228515625, 30.56699087315334 ], [ 9.393310546875, 30.56226095049944 ] ] ] } } ] }

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Saliha Alger

68206308

Date: 2021-07-01 08:57:11
Score: 2.5
Natty:
Report link
data = [(3, 0), (3, 6), (9, 6), (9, 9), (13, 10), (13, 1), (16, 8), (12, 17), (20, 18), (10, 21), (24, 17), (8, 25), (28, 25), (18, 31), (32, 8), (19, 33), (29, 33), (34, 37), (34, 19), (33, 37), (35, 40), (40, 24), (40, 50), (46, 40), (40, 40), (11, 43), (43, 47), (43, 26), (35, 46), (42, 49), (52, 44), (46, 53), (54, 36), (57, 37), (70, 60), (26, 63), (39, 66), (69, 44)]

df = pd.DataFrame(data, columns=["A", "B"])

output:
    A   B
0   3   0
1   3   6
2   9   6
3   9   9
4   13  10
....
Reasons:
  • Has code block (-0.5):
  • No latin characters (3):
Posted by: Tom McLean

68198169

Date: 2021-06-30 17:07:34
Score: 4.5
Natty:
Report link
!\[([^\]]*)\]\((.*?)\s*("(?:.*[^"])")?\s*\)
Reasons:
  • Low length (1.5):
  • Has code block (-0.5):
  • Has no white space (0.5):
  • No latin characters (3):
Posted by: Juergen

68188430

Date: 2021-06-30 05:29:55
Score: 6.5
Natty:
Report link

+9989994312941624939282459152+9989370313311624939219493

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Davron Ochilov

68178442

Date: 2021-06-29 13:14:58
Score: 1.5
Natty:
Report link

The problem is that the solvers will try to expand the expression that you have and these expressions become large when expanded so this is slow. Expansion is generally necessary for a system of linear equations for symbolic cancellation. In this case since it is only a single equation you can skip that step if you are sure that there is a unique solution:

In [41]: a = Wild('a')

In [42]: b = Wild('b')

In [43]: match = eq[0].match(a*s[0]+b)

In [44]: sol = -match[b]/match[a]

In [45]: sol
Out[45]: 
             ⎛                     2                      2                                                                                                 
    ⎛     2⎞ ⎜               2⋅D₁⋅k ⋅u + 2⋅c⋅u + d⋅v - 3⋅u ⋅v                                                                                               
2⋅u⋅⎝d + u ⎠⋅⎜───────────────────────────────────────────────────────────── + ──────────────────────────────────────────────────────────────────────────────
             ⎜    2  4           2         2          2                2  2     ⎛     3     8       3    6       3  6  2        2       6         2     6   
             ⎝2⋅D₁ ⋅k  + 4⋅D₁⋅c⋅k  - 8⋅D₁⋅k ⋅u⋅v + 2⋅c  - 8⋅c⋅u⋅v + 8⋅u ⋅v    2⋅⎝32⋅D₁ ⋅D₂⋅k  + 8⋅D₁ ⋅d⋅k  + 8⋅D₁ ⋅k ⋅u  + 72⋅D₁ ⋅D₂⋅c⋅k  - 144⋅D₁ ⋅D₂⋅k ⋅u⋅
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                                                                   2    4         2  4  3              2    
                                                                                                               8⋅D₁ ⋅d⋅k ⋅u + 8⋅D₁ ⋅k ⋅u  + 10⋅D₁⋅c⋅d⋅k ⋅u +
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
         2      4        2    4  2       2      4        2    4           2    4  2        2  4  3               2  4                4                  4  2
v + 18⋅D₁ ⋅c⋅d⋅k  + 18⋅D₁ ⋅c⋅k ⋅u  - 2⋅D₁ ⋅d⋅h⋅k  - 32⋅D₁ ⋅d⋅k ⋅u⋅v - 2⋅D₁ ⋅h⋅k ⋅u  - 32⋅D₁ ⋅k ⋅u ⋅v + 48⋅D₁⋅D₂⋅c ⋅k  - 192⋅D₁⋅D₂⋅c⋅k ⋅u⋅v + 192⋅D₁⋅D₂⋅k ⋅u 
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

          2  3         2  2               2             2  2             2  3          2  4        2          2  3      2                        2          
 10⋅D₁⋅c⋅k ⋅u  + 4⋅D₁⋅d ⋅k ⋅v - 2⋅D₁⋅d⋅h⋅k ⋅u - 8⋅D₁⋅d⋅k ⋅u ⋅v - 2⋅D₁⋅h⋅k ⋅u  - 12⋅D₁⋅k ⋅u ⋅v + 2⋅c ⋅d⋅u + 2⋅c ⋅u  + c⋅d ⋅v - 2⋅c⋅d⋅h⋅u - 2⋅c⋅d⋅u ⋅v - 2⋅c⋅h
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
  2          2    2          2  2  2               2              2                 2  2            2  3               2                2  2  2           2 
⋅v  + 12⋅D₁⋅c ⋅d⋅k  + 12⋅D₁⋅c ⋅k ⋅u  - 4⋅D₁⋅c⋅d⋅h⋅k  - 40⋅D₁⋅c⋅d⋅k ⋅u⋅v - 4⋅D₁⋅c⋅h⋅k ⋅u  - 40⋅D₁⋅c⋅k ⋅u ⋅v + 8⋅D₁⋅d⋅h⋅k ⋅u⋅v + 32⋅D₁⋅d⋅k ⋅u ⋅v  + 8⋅D₁⋅h⋅k ⋅
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                   2                                                                                                                        
                               D₁⋅k  + c - 2⋅u⋅v                                                                                                            
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

  3        4      2              2          4                                                                                                               
⋅u  - 3⋅c⋅u ⋅v - d ⋅h⋅v + 2⋅d⋅h⋅u ⋅v + 3⋅h⋅u ⋅v                                                                                                             
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
 3            2  4  2         3  2          2  2                2  2  2          2  3  3      3        3  2      2          2            2    2      2  3   
u ⋅v + 32⋅D₁⋅k ⋅u ⋅v  + 8⋅D₂⋅c ⋅k  - 48⋅D₂⋅c ⋅k ⋅u⋅v + 96⋅D₂⋅c⋅k ⋅u ⋅v  - 64⋅D₂⋅k ⋅u ⋅v  + 2⋅c ⋅d + 2⋅c ⋅u  - 2⋅c ⋅d⋅h - 8⋅c ⋅d⋅u⋅v - 2⋅c ⋅h⋅u  - 8⋅c ⋅u ⋅v 
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                               ⎞                                                                            
                                                                               ⎟                                                                            
───────────────────────────────────────────────────────────────────────────────⎟                                                                            
                       2  2          3          4  2          2  2        4  2⎞⎟                                                                            
+ 8⋅c⋅d⋅h⋅u⋅v + 8⋅c⋅d⋅u ⋅v  + 8⋅c⋅h⋅u ⋅v + 8⋅c⋅u ⋅v  - 8⋅d⋅h⋅u ⋅v  - 8⋅h⋅u ⋅v ⎠⎠                                                                            
──────────────────────────────────────────────────────────────────────────────── - ─────────────────────────────────────────────────────────────────────────
                                                                                        3     8       3    6       3  6  2        2       6        2     6  
                                                                                   16⋅D₁ ⋅D₂⋅k  + 4⋅D₁ ⋅d⋅k  + 4⋅D₁ ⋅k ⋅u  + 36⋅D₁ ⋅D₂⋅c⋅k  - 72⋅D₁ ⋅D₂⋅k ⋅u
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
         2      4       2    4  2     2      4        2    4         2    4  2        2  4  3               2  4               4                 4  2  2    
⋅v + 9⋅D₁ ⋅c⋅d⋅k  + 9⋅D₁ ⋅c⋅k ⋅u  - D₁ ⋅d⋅h⋅k  - 16⋅D₁ ⋅d⋅k ⋅u⋅v - D₁ ⋅h⋅k ⋅u  - 16⋅D₁ ⋅k ⋅u ⋅v + 24⋅D₁⋅D₂⋅c ⋅k  - 96⋅D₁⋅D₂⋅c⋅k ⋅u⋅v + 96⋅D₁⋅D₂⋅k ⋅u ⋅v  + 6
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                  ⎛           4              4  3             2             2  3         2  2             2  2           2  4  ⎞                            
                u⋅⎝4⋅D₁⋅D₂⋅d⋅k ⋅u + 4⋅D₁⋅D₂⋅k ⋅u  + 4⋅D₂⋅c⋅d⋅k ⋅u + 4⋅D₂⋅c⋅k ⋅u  + 2⋅D₂⋅d ⋅k ⋅v - 4⋅D₂⋅d⋅k ⋅u ⋅v - 6⋅D₂⋅k ⋅u ⋅v⎠                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
     2    2         2  2  2               2              2                 2  2            2  3               2                2  2  2           2  3       
⋅D₁⋅c ⋅d⋅k  + 6⋅D₁⋅c ⋅k ⋅u  - 2⋅D₁⋅c⋅d⋅h⋅k  - 20⋅D₁⋅c⋅d⋅k ⋅u⋅v - 2⋅D₁⋅c⋅h⋅k ⋅u  - 20⋅D₁⋅c⋅k ⋅u ⋅v + 4⋅D₁⋅d⋅h⋅k ⋅u⋅v + 16⋅D₁⋅d⋅k ⋅u ⋅v  + 4⋅D₁⋅h⋅k ⋅u ⋅v + 16
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                        2                                                                                                                   
                                  - D₁⋅k  - c + 2⋅u⋅v                                                                                                       

                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
     2  4  2         3  2          2  2                2  2  2          2  3  3    3      3  2    2          2          2    2      2  3                    
⋅D₁⋅k ⋅u ⋅v  + 4⋅D₂⋅c ⋅k  - 24⋅D₂⋅c ⋅k ⋅u⋅v + 48⋅D₂⋅c⋅k ⋅u ⋅v  - 32⋅D₂⋅k ⋅u ⋅v  + c ⋅d + c ⋅u  - c ⋅d⋅h - 4⋅c ⋅d⋅u⋅v - c ⋅h⋅u  - 4⋅c ⋅u ⋅v + 4⋅c⋅d⋅h⋅u⋅v + 4
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
───────────────────────────────────────────────────────────── - ────────────────────────────────────────────────────────────────────────────────────────────
      2  2          3          4  2          2  2        4  2   ⎛    2            ⎞ ⎛     3     8       3    6       3  6  2        2       6        2     6
⋅c⋅d⋅u ⋅v  + 4⋅c⋅h⋅u ⋅v + 4⋅c⋅u ⋅v  - 4⋅d⋅h⋅u ⋅v  - 4⋅h⋅u ⋅v    ⎝D₁⋅k  + c - 2⋅u⋅v⎠⋅⎝16⋅D₁ ⋅D₂⋅k  + 4⋅D₁ ⋅d⋅k  + 4⋅D₁ ⋅k ⋅u  + 36⋅D₁ ⋅D₂⋅c⋅k  - 72⋅D₁ ⋅D₂⋅k 
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
           2      4       2    4  2     2      4        2    4         2    4  2        2  4  3               2  4               4                 4  2  2  
⋅u⋅v + 9⋅D₁ ⋅c⋅d⋅k  + 9⋅D₁ ⋅c⋅k ⋅u  - D₁ ⋅d⋅h⋅k  - 16⋅D₁ ⋅d⋅k ⋅u⋅v - D₁ ⋅h⋅k ⋅u  - 16⋅D₁ ⋅k ⋅u ⋅v + 24⋅D₁⋅D₂⋅c ⋅k  - 96⋅D₁⋅D₂⋅c⋅k ⋅u⋅v + 96⋅D₁⋅D₂⋅k ⋅u ⋅v  +
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
     ⎛     2⎞ ⎛           4              4  3             2             2  3         2  2             2  2           2  4  ⎞                                
   v⋅⎝d + u ⎠⋅⎝4⋅D₁⋅D₂⋅d⋅k ⋅u + 4⋅D₁⋅D₂⋅k ⋅u  + 4⋅D₂⋅c⋅d⋅k ⋅u + 4⋅D₂⋅c⋅k ⋅u  + 2⋅D₂⋅d ⋅k ⋅v - 4⋅D₂⋅d⋅k ⋅u ⋅v - 6⋅D₂⋅k ⋅u ⋅v⎠                                
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
       2    2         2  2  2               2              2                 2  2            2  3               2                2  2  2           2  3     
 6⋅D₁⋅c ⋅d⋅k  + 6⋅D₁⋅c ⋅k ⋅u  - 2⋅D₁⋅c⋅d⋅h⋅k  - 20⋅D₁⋅c⋅d⋅k ⋅u⋅v - 2⋅D₁⋅c⋅h⋅k ⋅u  - 20⋅D₁⋅c⋅k ⋅u ⋅v + 4⋅D₁⋅d⋅h⋅k ⋅u⋅v + 16⋅D₁⋅d⋅k ⋅u ⋅v  + 4⋅D₁⋅h⋅k ⋅u ⋅v + 
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
       2  4  2         3  2          2  2                2  2  2          2  3  3    3      3  2    2          2          2    2      2  3                  
16⋅D₁⋅k ⋅u ⋅v  + 4⋅D₂⋅c ⋅k  - 24⋅D₂⋅c ⋅k ⋅u⋅v + 48⋅D₂⋅c⋅k ⋅u ⋅v  - 32⋅D₂⋅k ⋅u ⋅v  + c ⋅d + c ⋅u  - c ⋅d⋅h - 4⋅c ⋅d⋅u⋅v - c ⋅h⋅u  - 4⋅c ⋅u ⋅v + 4⋅c⋅d⋅h⋅u⋅v +
                                                                                                                                                            
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                                                                            
                                                                                                                                                            

                                                                                       
                                                                                       
                                                                                   2   
                                                                           ⎛     2⎞    
                                                                      0.75⋅⎝d + u ⎠    
──────────────────────────────────────────────────────────────── - ────────────────────
        2  2          3          4  2          2  2        4  2⎞                      2
 4⋅c⋅d⋅u ⋅v  + 4⋅c⋅h⋅u ⋅v + 4⋅c⋅u ⋅v  - 4⋅d⋅h⋅u ⋅v  - 4⋅h⋅u ⋅v ⎠   ⎛    2            ⎞ 
                                                                   ⎝D₁⋅k  + c - 2⋅u⋅v⎠ 
───────────────────────────────────────────────────────────────────────────────────────

Also note that there is a Float in there (0.75). I would make sure to use only rational numbers here because polynomial operations with floating point coefficients are not well defined.

Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low entropy (1):
  • High reputation (-1):
Posted by: Oscar Benjamin

68163622

Date: 2021-06-28 13:53:43
Score: 1
Natty:
Report link

We can stack several commands

>>> df.groupby(["id", "klass"])['varde'].apply(list).apply(pd.Series).reset_index()
    id  klass           0           1
0    0    1.0   53.801840   52.438421
1    0    2.0   88.804034  104.331863
2    1    1.0   58.524591   53.554198
3    1    2.0  105.083136  106.283919
4    2    1.0   51.879057   38.968125
5    2    2.0   96.204701  105.769039
6    3    1.0   48.391662   53.895055
7    3    2.0   94.890052   97.678197
8    4    1.0   48.451202   55.335374
9    4    2.0   90.846715  106.136627
10   5    1.0   53.072189   48.885893
11   5    2.0   99.433425   90.884468
12   6    1.0   55.418486   48.173335
13   6    2.0  113.972773  104.920153
14   7    1.0   56.561995   45.083425
15   7    2.0   94.816123   81.463938
16   8    1.0   59.161386   50.846878
17   8    2.0  114.141583  107.859278
18   9    1.0   53.033094   47.132339
19   9    2.0   91.235912   90.248085
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: crayxt

68156907

Date: 2021-06-28 03:37:26
Score: 5
Natty:
Report link
if ( i == j * (j+2) )
                  {
                      if(i == 0){
                          
                      } else{
                          printf("%d ", i);
                    break;
                      }
                    
                  }
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low entropy (1):
  • Low reputation (1):
Posted by: RoeiEilat

68155265

Date: 2021-06-27 22:09:53
Score: 4
Natty:
Report link

لابد من الاجابة على الاسئلة باللغة العربية حتى يتسنى للمبرمج العربي قراءة الحلول دون الحاجة الى ترجمة انا اعلم اهمية اللغة الانجليزية ولكن لماذا نحن العرب دائمًا نتعلم اللغة الانجليزية لماذا لا نجعل الردود العربية اكثر تطور وتكون ممتازة حتى الاجنبي نفسه انه يتعلم لغتنا الجميلة لابد انه يوجد لدينا الكثير من المبرمجين الرائعين والذين ينافسون على العالمية لماذا لا يكون واجهة للمجتمع العربي ويتم تغير الصورة النمطية التي حفرت في عقول الغرب اننا شعوب متخلفة او كما يقولوا نامية نحن متأخرين في التطور ولكن عقولنا جبارة تخدم في الغرب وهذه لوجود الحكومات الفاسدة التي لا تستثمر بالشباب سامحوني ان اطلت الكلام

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: yousf2050

68144758

Date: 2021-06-26 18:28:22
Score: 4
Natty:
Report link

Is this what you need?

df %>% 
    dplyr::filter(paste0(lubridate::year(date), "_", ID) %in% paste0(df2$year,"_", df2$ID))

         date        x        y ID
1  2010-12-26 74119.46 839347.8  1
2  2010-12-27 72401.02 891788.1  2
3  2010-12-31 66940.94 810089.6  1
4  2012-01-02 68214.97 881200.1  3
5  2012-01-07 70595.92 863277.7  3
6  2012-01-12 79799.85 857738.5  3
7  2012-01-17 61102.50 848880.6  3
8  2012-01-22 71798.29 883455.7  3
9  2012-01-27 61550.93 889447.7  3
10 2012-02-01 69863.50 838101.4  3
11 2012-02-06 71202.38 873705.6  3
12 2012-02-11 60124.56 828661.6  3
13 2012-02-16 65963.74 824347.5  3
14 2012-02-21 79347.69 818929.1  3
15 2012-02-26 68082.87 879863.1  3
16 2012-03-02 68661.00 891477.0  3
17 2012-03-07 71369.69 849595.6  3
18 2012-03-12 73265.85 834035.4  3
19 2012-03-17 70777.06 833344.5  3
20 2012-03-22 72104.04 881329.5  3
21 2012-03-27 75471.59 848650.2  3
22 2012-04-01 77590.13 867834.6  3
23 2012-04-06 75664.27 828857.6  3
24 2012-04-11 65789.62 814059.0  3
25 2012-04-16 72841.91 893683.3  3
26 2012-04-21 61047.06 805820.7  3
27 2012-04-26 77232.51 896022.5  3
28 2012-05-01 77553.05 817557.6  3
29 2012-05-06 75597.76 899616.4  3
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • Ends in question mark (2):
  • Starts with a question (0.5): Is this
  • No latin characters (3):
Posted by: user438383

68118242

Date: 2021-06-24 16:08:15
Score: 0.5
Natty:
Report link

Here is a solution with dplyr:

library(dplyr)

split_df <- df %>%
  arrange(desc(Value)) %>%
  split(c(rep("top", 10), rep("rest", nrow(.) - 10)))

bind_rows(split_df$top,
          tibble::tibble(ID = "Other",
                         Value = sum(split_df$rest$Value)))

Returns:

# A tibble: 11 x 2
   ID             Value
   <chr>          <dbl>
 1 63366849    42084408
 2 63475529    21879648
 3 6774736     21321888
 4 91274582    17393328
 5 63445915    15215002
 6 1097911044   9926442
 7 1095812405   8971332
 8 1097910557   5388376
 9 37548920     5114854
10 1005153076   5093730
11 Other      148494118

(Data used:)

df <- structure(list(ID = c("63366849", "63475529", "6774736", "91274582", "63445915", "1097911044", "1095812405", "1097910557", "37548920", "1005153076", "13513021", "51991938", "1010090155", "91265898", "91237574", "91344448", "1095956598", "28065538", "63341531", "63335642", "5637749", "17419836", "5567029", "5651301", "37839500", "63450446", "28424298", "29264885", "63328148", "63562603", "51702988", "7416450", "1005234045", "91520220", "91159937", "13801492", "9260536", "37722978", "63355924", "1098711718", "63443769", "60306461", "28485149", "2151526", "2127233", "1096063398", "27948572", "13834945", "27938888", "91179848", "41678031", "37837953", "91233367", "5557908", "28012681", "33446782", "91243709", "1007790961", "1095826946", "1095926858", "20189860", "24049724", "27903426", "28133395", "41446577", "37319481", "2033552", "27950302", "91200190", "91205127", "9527919", "1095303440", "13826841", "91218008", "63280472", "24074310", "37805433", "13801074", "28037341", "63353740", "1095793583", "1102371309", "1116493966", "2127316", "2153230", "37316948", "51778219", "5503745", "1099735096", "1222254600", "27786180", "2162536", "27964677", "2020408", "91349686", "37514200", "30208806", "1102351224", "28354311", "27929976", "63523710", "13838438", "28296329", "28410262", "28494063", "5721778", "91275248", "91353706", "37751608", "1097610166", "1098080648", "13810090", "63444976", "1221464992", "1097497475", "91100475", "1095312933", "28131889", "63506738", "7922341", "28238547", "27985819", "27958501", "23912889", "5707630", "1102388693", "24028654", "28128637", "5554160", "63369230", "36521093", "91525097", "27929902", "63441041", "1097919703", "40984557", "1097129811", "13843871", "63301433", "28236969", "37831774", "1000942168", "1005220322", "1098661759", "1095843775", "28399609", "37211106", "5683927", "28254346", "91268076", "28295325", "28496274", "13820294", "28354968", "37793321", "63495244", "63299126", "13849979", "63357743", "60262321", "1098753025", "91435400", "2195064", "63345546", "63251135", "13827671", "2007126", "40378506", "1097121371", "37828831", "5707059", "63324477", "1102644458", "37796841", "28334234", "28010824", "28495363", "27929493", "5558783", "51974763", "28296333", "63489129", "1102385538", "13814150", "13829893", "28377189", "91342964", "164497637", "52326169", "63286143", "1099738639", "63503298", "1097913686", "91070753", "37652636", "60352132"), Value = c(42084408, 21879648, 21321888, 17393328, 15215002, 9926442, 8971332, 5388376, 5114854, 5093730, 5004621, 3696756, 3424872, 3347432, 3337895, 3105759, 3104409, 3056238, 2748870, 2738808, 2662730, 2555784, 2268480, 2126700, 2051811, 2035200, 2025495, 1962000, 1926012, 1829736, 1822980, 1657659, 1574901, 1546320, 1539355, 1480530, 1456140, 1372302, 1372302, 1367235, 1350330, 1330560, 1327761, 1289520, 1265556, 1258350, 1245060, 1228770, 1228545, 1209705, 1196100, 1180533, 1175274, 1170286, 1144792, 1106820, 1106820, 1080621, 1080621, 1080621, 1080621, 1080621, 1080621, 1080621, 1080621, 1080264, 1067400, 1067400, 1003000, 993510, 992520, 988560, 957408, 957408, 922350, 889893, 888300, 883800, 855150, 835920, 833481, 833481, 833481, 833481, 833481, 833481, 833481, 833481, 823458, 775300, 741420, 734760, 734760, 729882, 672660, 666740, 631020, 621000, 621000, 600651, 598050, 553410, 553410, 553410, 553410, 553410, 553410, 553410, 552690, 503340, 468120, 439800, 416040, 415136, 403235, 398700, 383629, 383629, 383629, 367380, 364941, 360207, 360088, 346680, 339582, 339201, 339201, 339201, 339201, 303120, 300450, 289080, 282042, 238080, 234060, 219531, 211300, 195447, 195447, 192960, 192960, 169000, 169000, 169000, 163868, 163868, 156540, 143460, 136080, 132048, 127818, 127818, 124920, 124920, 124920, 124920, 105120, 93690, 93690, 77580, 66024, 64650, 62460, 62460, 62376, 58800, 58338, 57240, 50524, 49260, 49260, 48240, 46528, 44100, 43110, 42930, 41640, 40755, 38715, 37050, 35685, 33012, 30687, 28620, 28620, 24678, 24570, 15189, 15120, 15120, 14504, 14310, 11424, 6000, 5940, 5428)), row.names = c(NA, -196L), class = c("tbl_df", "tbl", "data.frame"))
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: ktiu

68109870

Date: 2021-06-24 06:04:02
Score: 7
Natty: 5.5
Report link

真的是太牛逼了,我已经无地自容 真的是太牛逼了,我已经无地自容 真的是太牛逼了,我已经无地自容

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: lalala

68093597

Date: 2021-06-23 05:43:56
Score: 8.5
Natty:
Report link

0000000000000000000pp000000000000

Reasons:
  • Low length (2):
  • No code block (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): 0000000000000000000
  • Filler text (0): 000000000000
  • Low entropy (1):
  • Low reputation (1):
Posted by: Lheeanne Rambuyon Paa

68073699

Date: 2021-06-21 20:37:10
Score: 0.5
Natty:
Report link

Prefer use setdefault method from dict to fill your data:

data = {}

for entry in r.json()[1]:
    d = data.setdefault(entry['country']['value'], [])
    d.append([int(entry['date']), float(entry['value'])])
>>> data
{'Brazil': [[2016, 1795700168991.49],
  [2015, 1802214373741.32],
  [2014, 2455993625159.37],
  [2013, 2472806919901.67],
  [2012, 2465188674415.03],
  [2011, 2616200980392.16],
  [2010, 2208871646202.82],
  [2009, 1667019783585.08],
  [2008, 1695824565983.2],
  [2007, 1397084349956.35],
  [2006, 1107640289615.23],
  [2005, 891630177251.068],
  [2004, 669316654017.094],
  [2003, 558319920831.979],
  [2002, 507962487700.024],
  [2001, 559372276081.966],
  [2000, 655420645476.906],
  [1999, 599388579985.673],
  [1998, 863723411632.917],
  [1997, 883199625324.675],
  [1996, 850426432991.742],
  [1995, 769305386182.849],
  [1994, 558111997497.263],
  [1993, 437798577639.752],
  [1992, 400599250000.0],
  [1991, 602860000000.0],
  [1990, 461951782000.0]],
 'China': [[2016, 11233276536737.2],
  [2015, 11061553079876.4],
  [2014, 10475682920594.5],
  [2013, 9570406235659.64],
  [2012, 8532229986993.65],
  [2011, 7551500124203.36],
  [2010, 6087163874512.21],
  [2009, 5101703073086.04],
  [2008, 4594307032660.79],
  [2007, 3550342737010.84],
  [2006, 2752131773355.16],
  [2005, 2285965892360.54],
  [2004, 1955347004963.27],
  [2003, 1660287965662.68],
  [2002, 1470550015081.55],
  [2001, 1339395718865.3],
  [2000, 1211346869605.24],
  [1999, 1093997267271.06],
  [1998, 1029043097554.08],
  [1997, 961603952951.82],
  [1996, 863746717503.789],
  [1995, 734547898220.508],
  [1994, 564324670005.917],
  [1993, 444731282436.762],
  [1992, 426915712711.146],
  [1991, 383373318083.624],
  [1990, 360857912565.966]],
 'United States': [[2016, 18714960538000.0],
  [2015, 18224704440000.0],
  [2014, 17527163695000.0],
  [2013, 16784849196000.0],
  [2012, 16197007349000.0],
  [2011, 15542581104000.0],
  [2010, 14992052727000.0],
  [2009, 14448933025000.0],
  [2008, 14712844084000.0],
  [2007, 14451858656000.0],
  [2006, 13814611414000.0],
  [2005, 13036640230000.0],
  [2004, 12213729147000.0],
  [2003, 11458243878000.0],
  [2002, 10936419054000.0],
  [2001, 10581821399000.0],
  [2000, 10252345464000.0],
  [1999, 9630664202000.0],
  [1998, 9062818202000.0],
  [1997, 8577554457000.0],
  [1996, 8073122000000.0],
  [1995, 7639749000000.0],
  [1994, 7287236000000.0],
  [1993, 6858559000000.0],
  [1992, 6520327000000.0],
  [1991, 6158129000000.0],
  [1990, 5963144000000.0]]}
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Corralien

68068493

Date: 2021-06-21 14:12:27
Score: 0.5
Natty:
Report link

Slightly different code, aggregate-first, join-second:

results <- t_d[, .(vDensity_againts=mean(adisplacement)), by=.(Time, AgentID, SimulationID, N, discountFactor, aState)
    ][ dStat, on=.(Time, AgentID, SimulationID, N, discountFactor, aState == position)
      ][, vDensity_againts := fcoalesce(vDensity_againts, 0)]

results
#      Time AgentID SimulationID     N discountFactor aState vDensity_againts
#     <num>   <int>        <int> <int>          <num>  <int>            <num>
#  1:  4001       1            4    40              0      0                0
#  2:  4001       1            4    40              0      1                1
#  3:  4001       1            4    40              0      2                0
#  4:  4001       1            4    40              0      3                0
#  5:  4001       1            4    40              0      4                0
#  6:  4001       1            4    40              0      5                0
#  7:  4001       1            4    40              0      6                0
#  8:  4001       1            4    40              0      7                0
#  9:  4001       1            4    40              0      8                0
# 10:  4001       1            4    40              0      9                0
# 11:  4001       1            4    40              0     10                0
# 12:  4001       1            4    40              0     11               -1
# 13:  4001       1            4    40              0     12                0
# 14:  4001       1            4    40              0     13                0
# 15:  4001       1            4    40              0     14                0
# 16:  4001       1            4    40              0     15                0
# 17:  4001       1            4    40              0     16                0
# 18:  4001       2            4    40              0      0                0
# 19:  4001       2            4    40              0      1                1
# 20:  4001       2            4    40              0      2                0
# 21:  4001       2            4    40              0      3                0
# 22:  4001       2            4    40              0      4                0
# 23:  4001       2            4    40              0      5                0
# 24:  4001       2            4    40              0      6                0
# 25:  4001       2            4    40              0      7                0
# 26:  4001       2            4    40              0      8                0
# 27:  4001       2            4    40              0      9                0
# 28:  4001       2            4    40              0     10                0
# 29:  4001       2            4    40              0     11               -1
# 30:  4001       2            4    40              0     12                0
# 31:  4001       2            4    40              0     13                0
# 32:  4001       2            4    40              0     14                0
# 33:  4001       2            4    40              0     15                0
# 34:  4001       2            4    40              0     16                0
# 35:  4001       3            4    40              0      0                0
# 36:  4001       3            4    40              0      1                1
# 37:  4001       3            4    40              0      2                0
# 38:  4001       3            4    40              0      3                0
# 39:  4001       3            4    40              0      4                0
# 40:  4001       3            4    40              0      5                0
# 41:  4001       3            4    40              0      6                0
# 42:  4001       3            4    40              0      7                0
# 43:  4001       3            4    40              0      8                0
# 44:  4001       3            4    40              0      9                0
# 45:  4001       3            4    40              0     10                0
# 46:  4001       3            4    40              0     11               -1
# 47:  4001       3            4    40              0     12                0
# 48:  4001       3            4    40              0     13                0
# 49:  4001       3            4    40              0     14                0
# 50:  4001       3            4    40              0     15                0
# 51:  4001       3            4    40              0     16                0
# 52:  4001       4            4    40              0      0                0
# 53:  4001       4            4    40              0      1                0
# 54:  4001       4            4    40              0      2                0
# 55:  4001       4            4    40              0      3                0
# 56:  4001       4            4    40              0      4                0
# 57:  4001       4            4    40              0      5                0
# 58:  4001       4            4    40              0      6                0
# 59:  4001       4            4    40              0      7                0
# 60:  4001       4            4    40              0      8                0
# 61:  4001       4            4    40              0      9              -17
# 62:  4001       4            4    40              0     10                0
# 63:  4001       4            4    40              0     11                0
# 64:  4001       4            4    40              0     12                0
# 65:  4001       4            4    40              0     13                0
# 66:  4001       4            4    40              0     14                0
# 67:  4001       4            4    40              0     15               -5
# 68:  4001       4            4    40              0     16                0
# 69:  4001       5            4    40              0      0                0
# 70:  4001       5            4    40              0      1                0
# 71:  4001       5            4    40              0      2                0
# 72:  4001       5            4    40              0      3                0
# 73:  4001       5            4    40              0      4                0
# 74:  4001       5            4    40              0      5                0
# 75:  4001       5            4    40              0      6                0
# 76:  4001       5            4    40              0      7                0
# 77:  4001       5            4    40              0      8                0
# 78:  4001       5            4    40              0      9              -17
# 79:  4001       5            4    40              0     10                0
# 80:  4001       5            4    40              0     11                0
# 81:  4001       5            4    40              0     12                0
# 82:  4001       5            4    40              0     13                0
# 83:  4001       5            4    40              0     14                0
# 84:  4001       5            4    40              0     15               -5
# 85:  4001       5            4    40              0     16                0
#      Time AgentID SimulationID     N discountFactor aState vDensity_againts

Other than the change in name from position to aState (easily) changed), this is identical to your expected output:

Map(all.equal, results, expected)
# $Time
# [1] TRUE
# $AgentID
# [1] TRUE
# $SimulationID
# [1] TRUE
# $N
# [1] TRUE
# $discountFactor
# [1] TRUE
# $aState
# [1] TRUE
# $vDensity_againts
# [1] TRUE
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low entropy (1):
  • High reputation (-2):
Posted by: r2evans

68065110

Date: 2021-06-21 10:00:22
Score: 2
Natty:
Report link

Simply by taking odd numbers as your indices:

>>> a = np.asarray([[ 89,  65,   4,  86,  44, 137, 113, 124],
                    [ 88,  71,   2,  89,  40, 140, 109, 129],
                    [ 93,  71,   5,  87,  40, 139, 111, 129],
                    [ 87,  74,   6,  96,  47, 143, 113, 129],
                    [ 81,  74,   3,  99,  47, 144, 112, 129],
                    [ 86,  64,   4,  89,  47, 139, 115, 123],
                    [ 85,  76,   1,  93,  38, 142, 106, 132],
                    [ 89,  80,   4,  94,  38, 143, 107, 134],
                    [ 84,  68,   4,  93,  48, 141, 114, 125],
                    [ 95,  42,  14,  80,  65, 130, 135, 107],
                    [ 90,  35,   1,  67,  50, 124, 123, 104],
                    [ 68,  36,   1,  84,  63, 129, 126,  97]])

>>> idx = np.arange(1,a.shape[1] + 1, 2) #odd-numbered indices
>>> a[:, idx] = 200 - a[:, idx]

>>> a

array([[ 89, 135,   4, 114,  44,  63, 113,  76],
       [ 88, 129,   2, 111,  40,  60, 109,  71],
       [ 93, 129,   5, 113,  40,  61, 111,  71],
       [ 87, 126,   6, 104,  47,  57, 113,  71],
       [ 81, 126,   3, 101,  47,  56, 112,  71],
       [ 86, 136,   4, 111,  47,  61, 115,  77],
       [ 85, 124,   1, 107,  38,  58, 106,  68],
       [ 89, 120,   4, 106,  38,  57, 107,  66],
       [ 84, 132,   4, 107,  48,  59, 114,  75],
       [ 95, 158,  14, 120,  65,  70, 135,  93],
       [ 90, 165,   1, 133,  50,  76, 123,  96],
       [ 68, 164,   1, 116,  63,  71, 126, 103]])
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: pr94

68063790

Date: 2021-06-21 08:20:02
Score: 4.5
Natty:
Report link

[Key]ไม่อะไรที่แท้จริงด้วยตัวเอง; มันต้องใช้รหัสอื่น (โดยปกติคือรหัสไลบรารี) เพื่อตรวจสอบว่ามีอยู่แล้วและอนุมานความหมายพิเศษบางอย่าง - สันนิษฐานว่า "ถือว่านี่เป็นคีย์หลัก" เมื่อจัดการโดย ORM บางตัว มันไม่ได้เปลี่ยนแปลงอะไรเกี่ยวกับคอมไพเลอร์ C# หรือส่วนใด ๆ ของรันไทม์ .NET ยกเว้นส่วนที่ตรวจสอบอย่างชัดเจน โดยจะไม่เปลี่ยนวิธีการทำงานของความเท่าเทียมหรือการเปรียบเทียบของวัตถุ เป็นต้น มีแอตทริบิวต์เพียงเล็กน้อยที่ส่งผลกระทบโดยตรงต่อการทำงานของโค้ด

Reasons:
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Kronphan Muangbun

68062425

Date: 2021-06-21 05:57:02
Score: 1.5
Natty:
Report link

Try it online!

def sort_dict(d):
    return sorted(d.items(), key = lambda x: tuple(x[1].keys())[0])

dict_1 = {
    (40, 615): {1: ["03/02/2013"]},
    (40, 558): {1: ["03/20/2013"]},
    (40, 501): {1: ["04/03/2013"]},
    (40, 342): {1: ["04/04/2013"]},
    (40, 248): {1: ["04/08/2013"]},
    (40, 88): {1: ["04/12/2013"]},
    (40, 584): {8: ["06/21/2013"]},
    (40, 480): {2: ["04/12/2013"]},
    (40, 321): {2: ["04/12/2013"]},
    (40, 121): {2: ["04/13/2013"]},
    (40, 563): {3: ["04/15/2013"]},
    (40, 404): {3: ["04/24/2013"]},
    (40, 245): {3: ["04/26/2013"]},
    (40, 141): {3: ["04/26/2013"]},
    (40, 578): {4: ["04/29/2013"]},
    (40, 474): {4: ["04/30/2013"]},
    (40, 370): {4: ["04/30/2013"]},
    (40, 201): {7: ["06/20/2013"]},
    (64, 643): {5: ["05/03/2013"]},
    (40, 484): {5: ["05/08/2013"]},
    (40, 287): {5: ["05/31/2013"]},
    (40, 171): {5: ["05/31/2013"]},
    (40, 660): {6: ["06/03/2013"]},
    (40, 544): {6: ["06/04/2013"]},
    (40, 440): {6: ["06/12/2013"]},
    (40, 281): {6: ["06/12/2013"]},
    (40, 177): {6: ["06/12/2013"]},
    (40, 619): {7: ["06/13/2013"]},
    (40, 515): {7: ["06/14/2013"]},
    (40, 411): {7: ["06/18/2013"]},
    (40, 295): {7: ["06/19/2013"]},
    (40, 97): {7: ["06/21/2013"]},
}

print(sort_dict(dict_1))

Output:

[
    ((40, 615), {1: ["03/02/2013"]}),
    ((40, 558), {1: ["03/20/2013"]}),
    ((40, 501), {1: ["04/03/2013"]}),
    ((40, 342), {1: ["04/04/2013"]}),
    ((40, 248), {1: ["04/08/2013"]}),
    ((40, 88), {1: ["04/12/2013"]}),
    ((40, 480), {2: ["04/12/2013"]}),
    ((40, 321), {2: ["04/12/2013"]}),
    ((40, 121), {2: ["04/13/2013"]}),
    ((40, 563), {3: ["04/15/2013"]}),
    ((40, 404), {3: ["04/24/2013"]}),
    ((40, 245), {3: ["04/26/2013"]}),
    ((40, 141), {3: ["04/26/2013"]}),
    ((40, 578), {4: ["04/29/2013"]}),
    ((40, 474), {4: ["04/30/2013"]}),
    ((40, 370), {4: ["04/30/2013"]}),
    ((64, 643), {5: ["05/03/2013"]}),
    ((40, 484), {5: ["05/08/2013"]}),
    ((40, 287), {5: ["05/31/2013"]}),
    ((40, 171), {5: ["05/31/2013"]}),
    ((40, 660), {6: ["06/03/2013"]}),
    ((40, 544), {6: ["06/04/2013"]}),
    ((40, 440), {6: ["06/12/2013"]}),
    ((40, 281), {6: ["06/12/2013"]}),
    ((40, 177), {6: ["06/12/2013"]}),
    ((40, 201), {7: ["06/20/2013"]}),
    ((40, 619), {7: ["06/13/2013"]}),
    ((40, 515), {7: ["06/14/2013"]}),
    ((40, 411), {7: ["06/18/2013"]}),
    ((40, 295), {7: ["06/19/2013"]}),
    ((40, 97), {7: ["06/21/2013"]}),
    ((40, 584), {8: ["06/21/2013"]}),
]
Reasons:
  • Probably link only (1):
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Arty

68052961

Date: 2021-06-20 06:36:57
Score: 6.5
Natty:
Report link

تابلو فرش چهره را از سایت فرش کاشان مهر خرید کنید کنید

Reasons:
  • Low length (2):
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: farsh news

68041576

Date: 2021-06-18 22:27:41
Score: 0.5
Natty:
Report link

I hope this is what you are looking for:

library(dplyr)

df %>%
  mutate(across(2:9, ~ .x * (28.8372*28.8372*0.0001)))

   year     veg   wetland      crop   grass    Urban    Soiol    water    Total
1  2005 1782135 113711.81  98964.83 2207446 3876.679 3265.880 7085.762 59030603
2  2006 1719688 167937.41  97068.32 2218091 3936.553 2952.207 6811.838 59030603
3  2007 1755638 122799.61  94299.72 2229590 3978.215 3171.662 6858.656 59030603
4  2008 1779052  97385.73 101739.74 2225128 3996.843 2254.591 6929.008 59030603
5  2009 1805124  74061.80 109175.68 2215820 4126.570 1406.209 6771.506 59030603
6  2010 1716897 168013.92 108014.04 2210652 4210.892 1535.686 7162.683 59030603
7  2011 1736893 151980.31 113991.80 2200158 4259.790 1442.050 7759.179 59030603
8  2012 1757331 133273.24 125825.08 2185550 4419.454 1958.464 8129.566 59030603
9  2013 1639913 248584.77 140183.71 2171800 4531.052 2777.325 8687.476 59030603
10 2014 1657022 227375.14 180036.21 2136408 4631.840 2287.937 8724.398 59030603
11 2015 1720644 151089.43 190536.46 2138271 4733.709 2298.332 8911.754 59030603
12 2016 1662281 202916.33 210776.22 2124964 4803.063 2165.528 8575.961 59030603
13 2017 1716428 136156.43 230587.13 2117937 4809.716 2170.268 8386.941 59030603
14 2018 1638716 204483.20 255703.30 2101913 4931.959 2349.391 8366.651 59030603
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Anoushiravan R

68039714

Date: 2021-06-18 19:13:08
Score: 1.5
Natty:
Report link

You could do

df_all |>
  matrix(nrow = 12) |>
  as.data.frame()

returning (truncated):

         V1       V2       V3       V4       V5       V6       V7       V8
1  3.583938 6.071985 6.429908 4.632524 5.477596 4.548784 4.588537 5.487138
2  4.055486 5.828313 3.517980 7.242400 4.909442 6.149804 3.990672 6.752652
3  3.710380 4.001795 5.739687 3.479396 6.191938 5.578237 3.252641 6.070115
4  4.867136 5.191307 5.884153 4.647208 5.437753 3.455165 5.989859 7.442414
5  5.111246 5.882136 6.361230 5.186235 3.867077 5.631055 5.030219 4.595383
6  5.061778 5.560719 4.146807 5.341364 2.919934 3.305795 5.129994 6.159989
7  6.188377 4.606850 6.693071 6.997215 5.722066 5.307161 4.795347 5.122470
8  4.035036 4.785901 3.325937 4.907982 5.490938 6.416011 7.522089 6.845924
9  6.152382 3.506762 4.541983 4.166833 3.461948 4.155356 2.969548 4.585297
10 6.834143 5.818803 5.048908 2.944199 4.999610 4.892196 4.242976 4.337777
11 4.293846 4.744218 4.244750 4.261823 4.552857 3.965914 4.560048 4.257186
12 5.605399 6.246158 6.622988 7.637657 5.349231 4.258165 4.357449 5.635602

Data used:

df_all <- rnorm(500, mean = 5, sd = 1)
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
Posted by: ktiu

68032357

Date: 2021-06-18 10:10:17
Score: 6
Natty:
Report link
IMG SRC=X ONERROR="javascript:alert('XSS')"
Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: John Jois M

68026864

Date: 2021-06-17 22:50:27
Score: 2
Natty:
Report link

An alternate NumPy solution:

>>> import numpy as np
>>> seed = np.random.random((10,5))
>>> seed
array([[0.43419963, 0.12927612, 0.47783417, 0.6698047 , 0.43966626],
       [0.56238954, 0.90856671, 0.84653548, 0.54566383, 0.98273554],
       [0.13319855, 0.14511374, 0.44135731, 0.57732303, 0.63272811],
       [0.67107476, 0.113417  , 0.25593979, 0.67509295, 0.35349618],
       [0.86125898, 0.21895507, 0.46389417, 0.18839496, 0.90046474],
       [0.03403771, 0.19303373, 0.02871153, 0.85036184, 0.95387585],
       [0.3316397 , 0.84540023, 0.97718179, 0.95335886, 0.9703442 ],
       [0.0221273 , 0.7636946 , 0.45536691, 0.64732677, 0.57123722],
       [0.40939072, 0.49219486, 0.90310105, 0.12079284, 0.41212587],
       [0.26332532, 0.52836011, 0.45873454, 0.69026349, 0.72141677]])
>>> board = np.where(seed < 0.2, 1, 0)
>>> board
array([[0, 1, 0, 0, 0],
       [0, 0, 0, 0, 0],
       [1, 1, 0, 0, 0],
       [0, 1, 0, 0, 0],
       [0, 0, 0, 1, 0],
       [1, 1, 1, 0, 0],
       [0, 0, 0, 0, 0],
       [1, 0, 0, 0, 0],
       [0, 0, 0, 1, 0],
       [0, 0, 0, 0, 0]])
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: Andrew Eckart

68015985

Date: 2021-06-17 09:55:16
Score: 3
Natty:
Report link

This should do the trick:

import numpy as np
import matplotlib.pyplot as plt

array = np.array([ 6.69444503, 6.62028965, 6.71395111, 6.70660448, 6.70821623, 6.66914818, 6.7160331 , 6.68638117, 6.75695725, 6.68171623, 6.73955838, 6.68919801, 6.76332219, 6.78286017, 6.81555002, 6.75381555, 6.75353165, 6.70909775, 6.74073086, 6.70899932, 6.6908525 , 6.59418955, 6.65966783, 6.65627975, 6.75186109, 6.71053962, 6.77552219, 6.78359504, 6.81006956, 6.76919262, 6.74450256, 6.74058832, 6.69536545, 6.6519225 , 6.62621774, 6.62584858, 6.67337241, 6.6917687 , 6.75191211, 6.75534094, 6.72788613, 6.68803099, 6.6613495 , 6.71848276, 6.75129579, 6.76199942, 6.73916056, 6.73957135, 6.76513941, 6.72795522, 6.63711679, 6.55248903, 6.61974385, 6.74794642, 6.88099129, 6.81151706, 6.7377934 , 6.65227642, 6.65518817, 6.6474948 , 6.67242465, 6.69769372, 6.77683837, 6.71750359, 6.70146931, 6.69701514, 6.77291463, 6.81000081, 6.73833814, 6.54288474, 6.64435143, 6.65653662, 6.87412486, 6.77087266, 6.92963172, 6.859477 , 6.92261811, 6.90716066, 6.95589443, 6.97304283, 6.97534776, 6.92405218, 6.8408661 , 6.83609476, 7.00246089, 7.05132823, 6.9246729 , 6.77486571, 6.8026577 , 6.91282969, 6.93526752, 6.96253309, 6.98858486, 6.85929044, 6.84243664, 6.77238593, 6.95158598, 6.91181849, 7.05094391, 6.97864081, 7.00878382, 6.82880079, 6.87036188, 6.90655258, 6.93307678, 6.94892631, 6.97922417, 7.0470304 , 7.15139031, 7.15694858, 7.1192599 , 7.05265314, 7.07909791, 7.1168476 , 7.12643587, 7.15610456, 7.19698636, 7.09834314, 7.05124444, 7.06147316, 7.29265349, 7.38762255, 7.19255318, 7.0914197 , 6.99632408, 7.28783749, 7.40642556, 7.50042657, 7.52199961, 7.38090861, 7.31366312, 7.32918037, 7.41356871, 7.40686241, 7.34454923, 7.35754063, 7.36483637, 7.52229303, 7.45715298, 7.54329464, 7.35501191, 7.41806418, 7.37864369, 7.3268464 , 7.20434605, 6.99586801, 6.93583466, 7.11969473, 7.15938148, 7.44589042, 7.34313421, 7.30155559, 7.28786179, 7.36995234, 7.3420818 , 7.17021967, 7.27735024, 7.37770573, 7.41216788, 7.32619126, 7.48962489, 7.34112295, 7.35875597, 7.0881354 , 7.46850535, 7.47971955, 7.75637784, 7.64789912, 7.60647042, 7.65423208, 7.75347939, 7.87979044, 7.68933715, 7.70211081, 7.51374563, 7.57404798, 7.58926237, 7.84621756, 7.99034484, 8.04283399, 7.97958613, 7.93807446, 7.98169401, 7.8776668 , 7.73453558, 7.74164658, 7.97903408, 8.10268243, 8.03542065, 8.10972688, 8.04294297, 8.05633646, 8.03725912, 8.25983391, 8.38995519, 8.36962264, 8.17699733, 8.21024941, 8.39719101, 8.62435624, 8.66466254, 8.53202815, 8.59849915, 8.55345886, 8.7359906 , 8.61148309, 8.66471803, 8.58964817, 8.37817649, 8.4487452 , 8.29727521, 8.80497468, 9.13774425, 9.23056669, 9.05938092, 8.92915832, 8.95605045, 9.19371233, 9.21134305, 9.32966008, 9.44885488, 9.60703095, 9.68599202, 9.73857392, 9.58981375, 9.69326948, 9.69908055, 9.61247299, 9.59321922, 9.72546618, 9.82947886, 9.88234468, 9.80105886, 9.90076688, 9.88697706, 9.93188788, 10.07941562, 10.1883549 , 10.26928882, 10.24549213, 10.38841197, 10.56229069, 10.73973299, 10.68900618, 10.56318566, 10.8720509 , 11.10384486, 11.21957039, 11.08780539, 11.1755498 , 11.29213701, 11.66953016, 11.85629452, 12.08136708, 12.31552502, 12.54267264, 12.7436129 , 12.70261375, 12.63184165, 12.3234958 , 12.10415375, 11.75131106, 11.67532432, 11.51112149, 11.43912942, 11.27077754, 11.12796411, 10.98608465, 10.95421553, 10.81817012, 10.60892879, 10.34879649, 10.24336291, 10.18332674, 10.26584287, 10.34229355, 10.35252445, 10.21730733, 10.10098059, 10.03168354, 9.95282456, 9.79382044, 9.71416103, 9.59824455, 9.62126605, 9.41602153, 9.43508821, 9.30142416, 9.37191569, 9.36895303, 9.52453799, 9.32715386, 9.1983345 , 9.06336403, 9.19879466, 9.06028903, 8.93720321, 8.91570714, 8.91893331, 8.9922376 , 9.01113625, 9.14272431, 9.09864042, 9.00019683, 8.70994841, 8.65760632, 8.71252674, 8.83044602, 8.7077489 , 8.44856982, 8.36202746, 8.49380112, 8.43758768, 8.51522822, 8.39732377, 8.38316112, 8.16890344, 8.13487416, 8.10955735, 8.09696699, 8.02992363, 8.17105347, 8.18225026, 8.13724563, 8.0722829 , 8.25107359, 8.17611697, 8.04802661, 7.80321978, 7.88329972, 7.93738869, 7.90669758, 8.01759731, 8.04220377, 7.90675838, 7.70493407, 7.53787673, 7.62073091, 7.52546029, 7.70095934, 7.84623128, 8.0006942 , 7.89516578, 7.74835171, 7.64721769, 7.53282095, 7.64161662, 7.55674742, 7.62838586, 7.48794439, 7.42979731, 7.47872707, 7.48249818, 7.45731704, 7.27393537, 7.44293302, 7.50772531, 7.60515245, 7.43210472, 7.44673673, 7.45097998, 7.47935287, 7.35754501, 7.15439062, 7.13837326, 7.2174589 , 7.25192887, 7.18308351, 7.09712443, 7.15393078, 7.11611744, 6.98504757, 6.96222427, 7.23452273, 7.38547407, 7.4523931 , 7.44356096, 7.42744486, 7.40436835, 7.23342905, 7.09705073, 7.12021193, 7.24969532, 7.23342225, 7.22111859, 7.11009096, 7.23244932, 7.05444443, 7.11840265, 7.23738078, 7.238834 , 7.13244689, 7.02936601, 7.07470322, 7.18216904, 7.06915501, 7.10676358, 6.99505972, 7.03908845, 7.19477338, 7.28860964, 7.23505325, 7.09765474, 7.04976001, 7.04160299, 7.04334479, 7.1015781 , 7.18696615, 7.09222292, 6.97253299, 6.93880034, 7.03973312, 7.11494813, 7.03234211, 6.98742809, 6.77929055, 6.84197639, 6.95866474, 6.98850632, 6.99234258, 6.80117981, 6.79377084, 6.67441952, 6.71621183, 6.6648103 , 6.75270579, 6.73731868, 6.86448484, 6.82328277, 6.74100421, 6.73419727, 6.71847507, 6.87672801, 6.92205112, 7.02398639, 6.9724521 , 6.86443623, 6.76949467, 6.68317052, 6.67938603, 6.64126311, 6.71279214, 6.77487357, 6.82779673, 6.71670699, 6.61091739, 6.59593221, 6.69074946, 6.81515364, 6.76440899, 6.78353573, 6.72608694, 6.7629007 , 6.74374407, 6.71517095, 6.67005636, 6.67293791, 6.72497808, 6.76154375, 6.74949199, 6.70005328, 6.72457262, 6.76483267, 6.78789715, 6.78164388, 6.7401589 , 6.78448831, 6.77338756, 6.80087043, 6.75914855, 6.73225717, 6.70224985, 6.70150418, 6.66315441, 6.67396018, 6.6377038 , 6.69045353, 6.68431725, 6.76329228, 6.7355242 , 6.70520747, 6.61466211, 6.61972572, 6.64595276, 6.69601337, 6.70481754, 6.69784698, 6.63233624, 6.64712029, 6.76416368, 6.73909511, 6.71532065, 6.5486919 , 6.58517468, 6.61351347, 6.63310043, 6.62013832, 6.62029447, 6.61951258, 6.6607056 , 6.6548232 , 6.6497125 , 6.69929709, 6.68842114, 6.74815417, 6.73749318, 6.75484044, 6.71556177, 6.56280052, 6.48748225, 6.49914832, 6.5760775 ])

ptMax = np.argmax(array), np.max(array)
nbPairs = min(ptMax[0], len(array) - ptMax[0])

for i in range(1, nbPairs):
    xDist = 2*i
    yDist = array[ptMax[0]+i] - array[ptMax[0]-i]
    # print(xDist, yDist)
    plt.plot([ptMax[0] - i, ptMax[0] - i + xDist], [array[ptMax[0]-i], array[ptMax[0]-i] + yDist], color="black")

plt.plot(array, '+', markersize=6)
plt.plot(ptMax[0], ptMax[1], 'ro')
plt.show()

You just need to be careful that the points are in the right order in your array.

Result:
enter image description here

Reasons:
  • Probably link only (1):
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: Gruvw

67998608

Date: 2021-06-16 09:03:09
Score: 7
Natty: 5.5
Report link

고맙습니다 고수님 사랑합니다. 당신은 저의 생명의 은인입니다.

Reasons:
  • Low length (2):
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: user16241073

67983106

Date: 2021-06-15 10:02:00
Score: 5
Natty:
Report link

Her are some of the first rows:
707057500080320020,"00.200","25.02.2019 05.00.00",2,92
707057500080320020,"00.200","25.02.2019 06.00.00",3,04
707057500080320020,"00.200","25.02.2019 07.00.00",3,13
707057500080320020,"00.200","25.02.2019 08.00.00",4,05
707057500080320020,"00.200","25.02.2019 09.00.00",2,96
707057500080320020,"00.200","25.02.2019 10.00.00",4,56
707057500080320020,"00.200","25.02.2019 11.00.00",3,88
707057500080320020,"00.200","25.02.2019 12.00.00",3,52

Reasons:
  • No code block (0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Anders Schjølberg

67964576

Date: 2021-06-14 04:51:17
Score: 8.5
Natty:
Report link

‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏  

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): ‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏
  • Low entropy (1):
  • Low reputation (1):
Posted by: user16218938

67959858

Date: 2021-06-13 16:29:47
Score: 6.5
Natty:
Report link

سلام عليكم ورحمة الله وبركاته اليكم لان كود سكر تيتان

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: AYMEN AYMEN

67950182

Date: 2021-06-12 16:18:58
Score: 4.5
Natty:
Report link
s = "1, 2, 3, 4,"
s1=s[:-1]
In : s1                                                                   
Out: '1, 2, 3, 4'
Reasons:
  • Low length (1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Jerzy Jamroz

67948218

Date: 2021-06-12 12:10:39
Score: 5.5
Natty:
Report link

أفضل اقتراح هو استبعاد الأحرف الخاصة من أسماء الملفات / الروابط / العناوين. لقد واجهت مشكلة مماثلة منذ بضع سنوات مع روابط تحتوي على ä ، ö ، ü ، والتي تم حلها ببساطة عن طريق إزالة الأحرف الخاصة واستبدالها بأحرف UTF-8 القياسية.

تيوتك

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: microtec

67932092

Date: 2021-06-11 07:23:38
Score: 1.5
Natty:
Report link

you can use module PIL and numpy to do it.

code:

from PIL import Image
from numpy import asarray

#convert your png file to data
img = Image.open('Sample.png')
print(list(img.getdata()))
numpydata = asarray(img)

#re-draw the picture from data
redraw_img = Image.fromarray(numpydata)
redraw_img.show()#show a picture exactly the same as the OP's picture

result:

[(1, 1, 1), (0, 0, 0), (1, 1, 1), (2, 2, 2), (2, 2, 2), (2, 2, 2), (6, 6, 6), (12, 12, 12), (17, 17, 17), (33, 33, 33), (51, 51, 51), (75, 75, 75), (105, 105, 105), (134, 134, 134), (164, 164, 164), (192, 192, 192), (211, 211, 211), (228, 228, 228), (239, 239, 239), (246, 246, 246), (254, 254, 254), (255, 255, 255), (254, 254, 254), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (254, 254, 254), (254, 254, 254), (255, 255, 255), (255, 255, 255), (254, 254, 254), (254, 254, 254), (253, 253, 253), (253, 253, 253), (255, 255, 255), (255, 255, 255), (255, 255, 255), (254, 254, 254), (254, 254, 254), (253, 253, 253), (253, 253, 253), (252, 252, 252), (249, 249, 249), (248, 248, 248), (247, 247, 247), (245, 245, 245), (243, 243, 243), (241, 241, 241), (239, 239, 239), (237, 237, 237), (239, 239, 239), (237, 237, 237), (235, 235, 235), (235, 235, 235), (236, 236, 236), (236, 236, 236), (236, 236, 236), (236, 236, 236), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (235, 235, 235), (234, 234, 234), (234, 234, 234), (234, 234, 234), (234, 234, 234), (233, 233, 233), (232, 232, 232), (231, 231, 231), (231, 231, 231), (231, 231, 231), (228, 228, 228), (223, 223, 223), (219, 219, 219), (214, 214, 214), (207, 207, 207), (197, 197, 197), (187, 187, 187), (177, 177, 177), (166, 166, 166), (154, 154, 154), (146, 146, 146), (134, 
134, 134), (127, 127, 127), (118, 118, 118), (111, 111, 111), (108, 108, 108), (105, 105, 105), (102, 102, 102), (99, 99, 99), (97, 97, 97), (97, 97, 97), (96, 96, 96), (96, 96, 96), (96, 96, 96), (96, 96, 96), (97, 97, 97), (97, 97, 97), (96, 96, 96), (98, 98, 98), (100, 100, 100), (103, 103, 103), (106, 106, 106), (110, 110, 110), (114, 114, 114), (117, 117, 117), (123, 123, 123), (128, 128, 128), (135, 135, 135), (140, 140, 140), (145, 145, 145), (151, 151, 151), (161, 161, 161), (168, 168, 168), (173, 173, 173), (179, 179, 179), (188, 188, 188), (194, 194, 194), (200, 200, 200), (206, 206, 206), (214, 214, 214), (220, 220, 220), (224, 224, 224), (228, 228, 228), (233, 233, 233), (238, 238, 238), (241, 241, 241), (243, 243, 243), (246, 246, 246), (248, 248, 248), (249, 249, 249), (250, 250, 250), (251, 251, 251), (252, 252, 252), (253, 253, 253), (253, 253, 253), (254, 254, 254), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (254, 254, 254), (253, 253, 253), (252, 252, 252), (253, 253, 253), (253, 253, 253), (250, 250, 250), (247, 247, 247), (245, 245, 245), (243, 243, 243), (238, 238, 238), (232, 232, 232), (226, 226, 226), (218, 218, 218), (211, 211, 211), (202, 202, 202), (193, 193, 193), (187, 187, 187), (180, 180, 180), (172, 172, 172), (166, 166, 166), (163, 163, 163), (160, 160, 160), (159, 159, 159), (160, 160, 160), (164, 164, 164), (168, 168, 168), (177, 177, 177), (185, 185, 185), (196, 196, 196), (203, 203, 203), (214, 214, 214), (224, 224, 224), (231, 231, 231), (238, 238, 238), (244, 244, 244), (248, 248, 248), (251, 251, 251), (254, 254, 254), (254, 254, 254), (253, 253, 253), (253, 253, 253), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 
255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), 
(255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (1, 1, 1), (0, 0, 0), (0, 0, 0), (1, 1, 1), (1, 1, 1), (1, 1, 1), (5, 5, 5), (11, 11, 11), (18, 18, 18), (34, 34, 34), (51, 51, 51), (75, 75, 75), (105, 105, 105), (133, 133, 133), (162, 162, 162), (190, 190, 190), (212, 212, 212), (228, 228, 228), (239, 239, 
239), (245, 245, 245), (254, 254, 254), (255, 255, 255), (254, 254, 254), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (254, 254, 254), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (254, 254, 254), (254, 254, 254), (254, 254, 254), (253, 253, 253), (253, 253, 253), (252, 252, 252), (251, 251, 251), (250, 250, 250), (248, 248, 248), (247, 247, 247), (244, 244, 244), (242, 242, 242), (240, 240, 240), (237, 237, 237), (235, 235, 235), (232, 232, 232), (228, 228, 228), (226, 226, 226), (225, 225, 225), (224, 224, 224), (222, 222, 222), (221, 221, 221), (221, 221, 221), (222, 222, 222), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (221, 221, 221), (220, 220, 220), (220, 220, 220), (220, 220, 220), (220, 220, 220), (219, 219, 219), (220, 220, 220), (219, 219, 219), (217, 217, 217), (217, 217, 217), (216, 216, 216), (213, 213, 213), (208, 208, 208), (203, 203, 203), (196, 196, 196), (188, 188, 188), (177, 177, 177), (165, 165, 165), (154, 154, 154), (141, 141, 141), (128, 128, 128), (119, 119, 119), (108, 108, 108), (102, 102, 102), (93, 93, 93), (86, 86, 86), (83, 83, 83), (80, 80, 80), (77, 77, 77), (74, 74, 74), (72, 72, 72), (72, 72, 72), (71, 71, 71), (71, 71, 71), (71, 71, 71), (71, 71, 71), (72, 72, 72), (72, 72, 72), (71, 71, 71), (73, 73, 73), (76, 76, 
76), (78, 78, 78), (80, 80, 80), (84, 84, 84), (88, 88, 88), (91, 91, 91), (96, 96, 96), (101, 101, 101), (108, 108, 108), (113, 113, 113), (117, 117, 117), (124, 124, 124), (133, 133, 133), (140, 140, 140), (150, 150, 150), (156, 156, 156), (165, 165, 165), (172, 172, 172), (179, 179, 179), (187, 187, 187), (195, 195, 195), (202, 202, 202), (210, 210, 210), (215, 215, 215), (222, 222, 222), (228, 228, 228), (232, 232, 232), (236, 236, 236), (239, 239, 239), (242, 242, 242), (245, 245, 245), (247, 247, 247), (249, 249, 249), (250, 250, 250), (251, 251, 251), (251, 251, 251), (252, 252, 252), (253, 253, 253), (253, 253, 253), (254, 254, 254), (254, 254, 254), (253, 253, 253), (252, 252, 252), (251, 251, 251), (250, 
250, 250), (250, 250, 250), (248, 248, 248), (245, 245, 245), (241, 241, 241), (238, 238, 238), (234, 234, 234), (228, 228, 228), (220, 220, 220), (213, 213, 213), (203, 203, 203), 
(195, 195, 195), (184, 184, 184), (173, 173, 173), (164, 164, 164), (156, 156, 156), (146, 146, 146), (140, 140, 140), (137, 137, 137), (134, 134, 134), (132, 132, 132), (134, 134, 
134), (138, 138, 138), (143, 143, 143), (152, 152, 152), (161, 161, 161), (175, 175, 175), (184, 184, 184), (197, 197, 197), (210, 210, 210), (220, 220, 220), (229, 229, 229), (237, 237, 237), (242, 242, 242), (247, 247, 247), (251, 251, 251), (253, 253, 253), (252, 252, 252), (253, 253, 253), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), (255, 255, 255), ...

reference: https://www.geeksforgeeks.org/how-to-convert-images-to-numpy-array/

Reasons:
  • Whitelisted phrase (-1.5): you can use
  • Probably link only (1):
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: leaf_yakitori

67929357

Date: 2021-06-11 00:01:25
Score: 1.5
Natty:
Report link

A tidyverse option.

library(dplyr)
library(tidyr)

mutate(df, follow = if_else(follow == 1, 
                            cumsum(replace_na(lag(follow) < follow, 0)),
                            0)) 

#     trial time   X   Y follow
# 1       1    1 188  48      0
# 2       1    2  53 122      0
# 3       1    3 197 191      0
# 4       1    4 123  50      0
# 5       1    5  18 142      0
# 6       1    6  36  29      0
# 7       1    7 101 111      0
# 8       1    8  91  10      0
# 9       1    9 185  36      0
# 10      1   10  72  83      0
# 11      1   11 138  94      0
# 12      1   12 193  25      0
# 13      1   13  34  17      0
# 14      1   14  51 162      0
# 15      1   15 141 106      0
# 16      1   16  99 193      0
# 17      1   17  77  58      0
# 18      1   18  96  12      0
# 19      1   19  25 119      0
# 20      1   20 173  17      0
# 21      1   21  78 141      1
# 22      1   22  73 184      1
# 23      1   23 145 103      1
# 24      1   24 161  36      1
# 25      1   25  38  99      1
# 26      1   26  56 178      1
# 27      1   27  39  95      1
# 28      1   28 109  31      1
# 29      1   29 184 119      1
# 30      1   30  84 132      1
# 31      1   31 103 150      1
# 32      1   32 177  80      1
# 33      1   33 153 129      1
# 34      1   34 121  25      1
# 35      1   35 184 158      1
# 36      1   36 190  16      1
# 37      1   37  29 165      1
# 38      1   38 102  51      1
# 39      1   39 105  17      1
# 40      1   40  71   5      1
# 41      1   41  10   5      1
# 42      1   42 160  95      1
# 43      1   43 143  96      1
# 44      1   44 101  11      1
# 45      1   45 154 127      1
# 46      1   46  20 133      0
# 47      1   47 199 192      0
# 48      1   48  83   3      0
# 49      1   49  22  96      0
# 50      1   50  86  57      0
# 51      1   51 163  87      2
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
Posted by: rjen

67924724

Date: 2021-06-10 17:07:24
Score: 1
Natty:
Report link

Here is how I break it up:

"~-~--~~-~-1863408518" (going from left to right)

1111 1111 1111 1111 1111 1111 1111 1111 1001 0000 1110 1110 1010 0100 0111 1010 = -1863408518 
                                        0110 1111 0001 0001 0101 1011 1000 0101 (NOT)
1111 1111 1111 1111 1111 1111 1111 1111 1001 0000 1110 1110 1010 0100 0111 1011 (-)
                                        0110 1111 0001 0001 0101 1011 1000 0100 (NOT)
1111 1111 1111 1111 1111 1111 1111 1111 1001 0000 1110 1110 1010 0100 0111 1011 (NOT)
                                        0110 1111 0001 0001 0101 1011 1000 0101 (-)
1111 1111 1111 1111 1111 1111 1111 1111 1001 0000 1110 1110 1010 0100 0111 1011 (-)
                                        0110 1111 0001 0001 0101 1011 1000 0100 (NOT)
1111 1111 1111 1111 1111 1111 1111 1111 1001 0000 1110 1110 1010 0100 0111 1100 (-)
                                        0110 1111 0001 0001 0101 1011 1000 0011 (NOT)

110 1111 0001 0001 0101 1011 1000 0011 = 1,863,408,515

Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: SunsetQuest

67887971

Date: 2021-06-08 14:35:09
Score: 0.5
Natty:
Report link

you can transpose easily with numpy :

dataset_str = '''33,48216616 33,48225771 33,48234926 33,48244081 33,48253237 33,48262392 33,48271547 33,48280702 33,48289857 33,48299012 33,48308167 33,48317322 33,48326478 33,48335633 33,48344788 33,48353943 
33,48216601 33,48225756 33,48234912 33,48244067 33,48253222 33,48262377 33,48271532 33,48280687 33,48289842 33,48298997 33,48308153 33,48317308 33,48326463 33,48335618 33,48344773 33,48353928 
33,48216587 33,48225742 33,48234897 33,48244052 33,48253207 33,48262362 33,48271517 33,48280672 33,48289828 33,48298983 33,48308138 33,48317293 33,48326448 33,48335603 33,48344758 33,48353913 
33,48216572 33,48225727 33,48234882 33,48244037 33,48253192 33,48262347 33,48271502 33,48280658 33,48289813 33,48298968 33,48308123 33,48317278 33,48326433 33,48335588 33,48344743 33,48353899 
33,48216557 33,48225712 33,48234867 33,48244022 33,48253177 33,48262333 33,48271488 33,48280643 33,48289798 33,48298953 33,48308108 33,48317263 33,48326418 33,48335573 33,48344729 33,48353884 
33,48216542 33,48225697 33,48234852 33,48244008 33,48253163 33,48262318 33,48271473 33,48280628 33,48289783 33,48298938 33,48308093 33,48317248 33,48326404 33,48335559 33,48344714 33,48353869 
33,48216527 33,48225683 33,48234838 33,48243993 33,48253148 33,48262303 33,48271458 33,48280613 33,48289768 33,48298923 33,48308079 33,48317234 33,48326389 33,48335544 33,48344699 33,48353854 
33,48216513 33,48225668 33,48234823 33,48243978 33,48253133 33,48262288 33,48271443 33,48280598 33,48289754 33,48298909 33,48308064 33,48317219 33,48326374 33,48335529 33,48344684 33,48353839 
33,48216498 33,48225653 33,48234808 33,48243963 33,48253118 33,48262273 33,48271429 33,48280584 33,48289739 33,48298894 33,48308049 33,48317204 33,48326359 33,48335514 33,48344669 33,48353824 '''
arr1 = np.array([[float(number.replace(',',''))  for number in line.strip(' ').split(' ')] for line in dataset_str.split('\n') ])
arr2 = arr1 .T
print(arr2)

output:

array([[3.34821662e+09, 3.34821660e+09, 3.34821659e+09, 3.34821657e+09,
        3.34821656e+09, 3.34821654e+09, 3.34821653e+09, 3.34821651e+09,
        3.34821650e+09],
       [3.34822577e+09, 3.34822576e+09, 3.34822574e+09, 3.34822573e+09,
        3.34822571e+09, 3.34822570e+09, 3.34822568e+09, 3.34822567e+09,
        3.34822565e+09],
       [3.34823493e+09, 3.34823491e+09, 3.34823490e+09, 3.34823488e+09,
        3.34823487e+09, 3.34823485e+09, 3.34823484e+09, 3.34823482e+09,
        3.34823481e+09],
       [3.34824408e+09, 3.34824407e+09, 3.34824405e+09, 3.34824404e+09,
        3.34824402e+09, 3.34824401e+09, 3.34824399e+09, 3.34824398e+09,
        3.34824396e+09],
       [3.34825324e+09, 3.34825322e+09, 3.34825321e+09, 3.34825319e+09,
        3.34825318e+09, 3.34825316e+09, 3.34825315e+09, 3.34825313e+09,
        3.34825312e+09],
       [3.34826239e+09, 3.34826238e+09, 3.34826236e+09, 3.34826235e+09,
        3.34826233e+09, 3.34826232e+09, 3.34826230e+09, 3.34826229e+09,
        3.34826227e+09],
       [3.34827155e+09, 3.34827153e+09, 3.34827152e+09, 3.34827150e+09,
        3.34827149e+09, 3.34827147e+09, 3.34827146e+09, 3.34827144e+09,
        3.34827143e+09],
       [3.34828070e+09, 3.34828069e+09, 3.34828067e+09, 3.34828066e+09,
        3.34828064e+09, 3.34828063e+09, 3.34828061e+09, 3.34828060e+09,
        3.34828058e+09],
       [3.34828986e+09, 3.34828984e+09, 3.34828983e+09, 3.34828981e+09,
        3.34828980e+09, 3.34828978e+09, 3.34828977e+09, 3.34828975e+09,
        3.34828974e+09],
       [3.34829901e+09, 3.34829900e+09, 3.34829898e+09, 3.34829897e+09,
        3.34829895e+09, 3.34829894e+09, 3.34829892e+09, 3.34829891e+09,
        3.34829889e+09],
       [3.34830817e+09, 3.34830815e+09, 3.34830814e+09, 3.34830812e+09,
        3.34830811e+09, 3.34830809e+09, 3.34830808e+09, 3.34830806e+09,
        3.34830805e+09],
       [3.34831732e+09, 3.34831731e+09, 3.34831729e+09, 3.34831728e+09,
        3.34831726e+09, 3.34831725e+09, 3.34831723e+09, 3.34831722e+09,
        3.34831720e+09],
       [3.34832648e+09, 3.34832646e+09, 3.34832645e+09, 3.34832643e+09,
        3.34832642e+09, 3.34832640e+09, 3.34832639e+09, 3.34832637e+09,
        3.34832636e+09],
       [3.34833563e+09, 3.34833562e+09, 3.34833560e+09, 3.34833559e+09,
        3.34833557e+09, 3.34833556e+09, 3.34833554e+09, 3.34833553e+09,
        3.34833551e+09],
       [3.34834479e+09, 3.34834477e+09, 3.34834476e+09, 3.34834474e+09,
        3.34834473e+09, 3.34834471e+09, 3.34834470e+09, 3.34834468e+09,
        3.34834467e+09],
       [3.34835394e+09, 3.34835393e+09, 3.34835391e+09, 3.34835390e+09,
        3.34835388e+09, 3.34835387e+09, 3.34835385e+09, 3.34835384e+09,
        3.34835382e+09]])
(the shape now is (16, 9) instead of (9, 16))
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: adir abargil

67882346

Date: 2021-06-08 07:24:29
Score: 8.5
Natty:
Report link

А разве в этом коде не нужно переделать класс в стохастический спуск?

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Ends in question mark (2):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Алексей

67876990

Date: 2021-06-07 19:37:19
Score: 6
Natty:
Report link

Just go to sleep‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • No latin characters (3):
  • Low entropy (1):
  • Low reputation (1):
Posted by: F4x

67851512

Date: 2021-06-05 17:18:12
Score: 2.5
Natty:
Report link

It looks like this is what you want:

map2(x, y, ~ inner_join(.x, .y))
[[1]]
  i          x          z         x1         z1
1 1  0.7715183 -0.6933826 -0.3335239  0.5957587
2 2 -0.3824746 -0.7248827 -1.6736241 -1.2248904
3 3  0.3412777 -0.3711940  0.9334678  0.4043867
4 4 -0.4225862 -1.6653314  1.0369985  1.1808140
5 5  0.7468157  0.1704126 -0.1470796 -1.6237296

[[2]]
  i           x          z         x1          z1
1 1  0.69264103 -0.6640663 -0.2253319  0.26323254
2 2 -0.07861775  0.7914119  0.3725911  0.02854667
3 3 -0.86588724 -0.5519633 -1.5114177 -0.14283509
4 4  1.16069947  1.1299540 -0.4207173 -1.15829758
5 5  2.13867104 -0.9668079  0.1082068 -2.74714297
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: ktiu

67837306

Date: 2021-06-04 13:38:16
Score: 6.5
Natty:
Report link

Yes. .

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Low entropy (1):
Posted by: Tom V

67824810

Date: 2021-06-03 17:01:09
Score: 2.5
Natty:
Report link

Another option using genfilter :

library(data.table)
library(genefilter)


tnn=structure(c(1L, 19L, 5L, 6L, 10L, 2L, 4L, 7L, 12L, 1L, 3L, 4L, 
8L, 13L, 1L, 4L, 15L, 16L, 2L, 3L, 5L, 6L, 14L, 1L, 15L, 5L, 
6L, 14L, 1L, 15L, 7L, 2L, 9L, 17L, 4L, 8L, 3L, 9L, 18L, 4L, 9L, 
10L, 11L, 4L, 7L, 9L, 10L, 11L, 1L, 15L, 9L, 10L, 11L, 1L, 15L, 
12L, 2L, 14L, 17L, 4L, 13L, 3L, 14L, 18L, 4L, 5L, 6L, 14L, 4L, 
12L, 4L, 15L, 16L, 5L, 6L, 4L, 15L, 16L, 5L, 6L, 17L, 7L, 12L, 
19L, 2L, 18L, 8L, 13L, 19L, 3L, 1L, 19L, 9L, 14L, 17L), .Dim = c(5L, 
19L))


custom_fun<-function(x,y){
return(length(intersect(x,y)))
}

dist2(as.matrix(tnn),custom_fun,diagonal = 0)

      [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12] [,13]
 [1,]    0    1    1    0    3    3    0    0    1     2     2     0     0
 [2,]    1    0    2    2    1    1    3    1    2     1     1     3     1
 [3,]    1    2    0    2    1    1    1    3    1     1     1     1     3
 [4,]    0    2    2    0    1    1    2    2    1     1     1     2     2
 [5,]    3    1    1    1    0    5    0    0    0     2     2     1     1
 [6,]    3    1    1    1    5    0    0    0    0     2     2     1     1
 [7,]    0    3    1    2    0    0    0    2    3     1     1     3     1
 [8,]    0    1    3    2    0    0    2    0    2     1     1     1     3
 [9,]    1    2    1    1    0    0    3    2    0     3     3     1     1
[10,]    2    1    1    1    2    2    1    1    3     0     5     0     0
[11,]    2    1    1    1    2    2    1    1    3     5     0     0     0
[12,]    0    3    1    2    1    1    3    1    1     0     0     0     2
[13,]    0    1    3    2    1    1    1    3    1     0     0     2     0
[14,]    2    2    1    1    3    3    1    1    1     0     0     3     2
[15,]    2    1    1    3    3    3    1    1    1     1     1     1     1
[16,]    2    1    1    3    3    3    1    1    1     1     1     1     1
[17,]    1    3    0    1    0    0    3    0    1     0     0     3     0
[18,]    1    0    3    1    0    0    0    3    0     0     0     0     3
[19,]    2    1    1    0    2    2    2    1    1     2     2     2     1
      [,14] [,15] [,16] [,17] [,18] [,19]
 [1,]     2     2     2     1     1     2
 [2,]     2     1     1     3     0     1
 [3,]     1     1     1     0     3     1
 [4,]     1     3     3     1     1     0
 [5,]     3     3     3     0     0     2
 [6,]     3     3     3     0     0     2
 [7,]     1     1     1     3     0     2
 [8,]     1     1     1     0     3     1
 [9,]     1     1     1     1     0     1
[10,]     0     1     1     0     0     2
[11,]     0     1     1     0     0     2
[12,]     3     1     1     3     0     2
[13,]     2     1     1     0     3     1
[14,]     0     3     3     1     0     1
[15,]     3     0     5     0     0     0
[16,]     3     5     0     0     0     0
[17,]     1     0     0     0     1     2
[18,]     0     0     0     1     0     1
[19,]     1     0     0     2     1     0

 
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • No latin characters (3):
  • Low reputation (0.5):
Posted by: Tou Mou

67819989

Date: 2021-06-03 11:49:17
Score: 3.5
Natty:
Report link

Refer http://jsfiddle.net/Jainskumar7/0hndm6ja/ have the same dateTime on yAxis

series: [{
data: [[1621366784000,54],[1621368584000,55],[1621370384000,55],[1621372184000,56],[1621373984000,56],[1621375784000,56],[1621377583000,57],[1621379383000,57],[1621381183000,58],[1621382983000,59],[1621384783000,59],[1621386583000,60],[1621388383000,60],[1621390183000,60],[1621391983000,60],[1621393783000,60],[1621395583000,60],[1621397383000,59],[1621399183000,59],[1621400983000,59],[1621404583000,60],[1621406383000,60],[1621408183000,60],[1621409983000,59],[1621411783000,59],[1621413583000,58],[1621415383000,59],[1621417183000,59],[1621418983000,59],[1621420783000,58],[1621422583000,58],[1621424383000,58],[1621426183000,58],[1621427983000,58],[1621429782000,58],[1621431582000,58],[1621433382000,58],[1621435182000,58],[1621436982000,58],[1621438782000,58],[1621440582000,58],[1621442382000,58],[1621444182000,57],[1621595378000,49],[1621597178000,49],[1621598978000,49],[1621600778000,49],[1621602577000,48],[1621604377000,48],[1621606177000,47],[1621607977000,47],[1621705175000,52],[1621706975000,52],[1621708775000,52],[1621710575000,52],[1621712375000,52],[1621714175000,52],[1621715975000,52],[1621717774000,52],[1621719574000,52],[1621721375000,52],[1621723175000,52],[1621724975000,52],[1621726775000,52],[1621728575000,52],[1621730375000,51],[1621732175000,50],[1621733975000,50],[1621735775000,50],[1621737575000,50],[1621739375000,50],[1621741175000,50],[1621742975000,50],[1621744775000,50],[1621746574000,51],[1621748374000,51],[1621750174000,51],[1621751974000,51],[1621753774000,51],[1621755574000,51],[1621757374000,51],[1621759174000,51],[1621760974000,51],[1621762774000,52],[1621764574000,52],[1621924771000,44],[1621926571000,44],[1621928371000,43],[1621930171000,43]]

}]

Reasons:
  • Probably link only (1):
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Satyendra Jain

67818013

Date: 2021-06-03 09:34:06
Score: 7.5
Natty:
Report link

you can't .....................................................................................

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): .....................................................................................
  • Low entropy (1):
  • Low reputation (1):
Posted by: calozy 12

67814013

Date: 2021-06-03 01:32:52
Score: 0.5
Natty:
Report link

Another way:

data='''a  b
0     (45.349586099999996, -75.81031967988278)
1            (-37.77922725, 175.2010323246593)
2                   (-42.9945669, 170.7100413)
3                    (-39.2711067, 174.154795)
4                      (51.2800275, 1.0802533)
5           (-41.30222105, 172.89453190955697)
6                   (-35.3712702, 173.7405337)
7                   (-45.7255555, 168.2936808)
8                   (-40.3284102, 175.8190684)
9                   (-45.1299859, 169.5248818)
10           (-37.9503756, 176.93828736155422)'''        
df = pd.read_csv(io.StringIO(data), sep=' \s+', engine='python')
df[['lat', 'lon']] = df.b.str[1:-1].str.split(',', expand=True)

     a                                         b                 lat                  lon
0    0  (45.349586099999996, -75.81031967988278)  45.349586099999996   -75.81031967988278
1    1         (-37.77922725, 175.2010323246593)        -37.77922725    175.2010323246593
2    2                (-42.9945669, 170.7100413)         -42.9945669          170.7100413
3    3                 (-39.2711067, 174.154795)         -39.2711067           174.154795
4    4                   (51.2800275, 1.0802533)          51.2800275            1.0802533
5    5        (-41.30222105, 172.89453190955697)        -41.30222105   172.89453190955697
6    6                (-35.3712702, 173.7405337)         -35.3712702          173.7405337
7    7                (-45.7255555, 168.2936808)         -45.7255555          168.2936808
8    8                (-40.3284102, 175.8190684)         -40.3284102          175.8190684
9    9                (-45.1299859, 169.5248818)         -45.1299859          169.5248818
10  10         (-37.9503756, 176.93828736155422)         -37.9503756   176.93828736155422
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Jonathan Leon

67813223

Date: 2021-06-02 23:26:54
Score: 0.5
Natty:
Report link

The data is under a d attribute under the class sr-area sr-fill-home. Try to find it as follows:

from bs4 import BeautifulSoup

html = """ABOVE HTML SNIPPET"""
soup = BeautifulSoup(html, "html.parser")
for tag in soup.find_all(class_="sr-area sr-fill-home"):
    print(tag["d"])
    

Output:

M455.235,38L455.235,43.5C457.526,41.7,458.671,38.1,460.962,36.5C463.252,35.5,464.398,35.5,466.689,35.5C468.979,35.5,470.125,35.5,472.415,35.5C474.706,35.5,475.851,34.5,478.142,34.5C480.433,34.5,481.578,35.5,483.869,35.5C486.16,35.5,487.305,29.5,489.596,29.5C491.886,29.5,493.032,36.5,495.322,36.5C497.613,36.5,498.758,34.5,501.049,34.5C503.34,34.5,504.485,47.5,506.776,47.5C509.067,47.5,510.212,29.5,512.503,29.5C514.793,29.5,515.939,41.5,518.23,41.5C520.52,41.5,521.666,31.5,523.956,31.5C526.247,31.5,527.392,37.1,529.683,39.5L529.683,38Z
M432.328,38L432.328,52.5C434.619,52.5,435.764,24.5,438.055,24.5C440.345,24.5,441.491,32.3,443.781,36.5C446.072,40.7,447.217,45.5,449.508,45.5L449.508,38Z
M403.694,38L403.694,42.5C405.985,37.1,407.13,20.5,409.421,20.5C411.711,20.5,412.857,37.5,415.148,37.5C417.438,37.5,418.584,19.5,420.874,19.5C423.165,19.5,424.31,33.9,426.601,40.5L426.601,38Z
M380.787,38L380.787,46.5C383.078,46.5,384.223,40.1,386.514,37.5C388.804,34.9,389.95,33.5,392.24,33.5C394.531,33.5,395.677,47.5,397.967,47.5L397.967,38Z
M334.973,38L334.973,40.5C337.263,36.5,338.409,37.9,340.699,36.5C342.99,35.1,344.136,33.5,346.426,33.5C348.717,33.5,349.862,48.5,352.153,48.5L352.153,38Z
M226.164,38L226.164,50.5C228.455,45.5,229.6,33.5,231.891,33.5C234.181,33.5,235.327,39.5,237.617,39.5C239.908,39.5,241.054,20.5,243.344,20.5C245.635,20.5,246.78,29.7,249.071,32.5C251.362,34.5,252.507,34.5,254.798,34.5C257.089,34.5,258.234,21.5,260.525,21.5C262.815,21.5,263.961,42.5,266.251,42.5C268.542,42.5,269.687,24.3,271.978,19.5C274.269,18.5,275.414,18.5,277.705,18.5C279.996,18.5,281.141,18.5,283.432,18.5C285.722,18.5,286.868,30.7,289.158,34.5C291.449,37.5,292.595,37.5,294.885,37.5C297.176,37.5,298.321,25.5,300.612,25.5C302.903,25.5,304.048,39.5,306.339,39.5C308.63,39.5,309.775,28.3,312.066,24.5C314.356,20.7,315.502,20.5,317.792,20.5C320.083,20.5,321.228,44.1,323.519,51.5L323.519,38Z
M203.257,38L203.257,39.5C205.548,35.5,206.693,31.5,208.984,31.5C211.274,31.5,212.42,31.5,214.71,35.5C217.001,40.9,218.146,58.5,220.437,58.5L220.437,38Z
M186.077,38L186.077,46.5C188.367,46.5,189.513,29.5,191.803,29.5C194.094,29.5,195.239,51.5,197.53,51.5L197.53,38Z
M60.087,38L60.087,40.5C62.378,38.3,63.523,37.5,65.814,37.5C68.105,37.5,69.25,55.5,71.541,55.5C73.832,55.5,74.977,36.5,77.268,36.5C79.558,36.5,80.704,36.5,82.995,36.5C85.285,36.5,86.431,33.5,88.721,33.5C91.012,33.5,92.157,40.5,94.448,40.5C96.739,40.5,97.884,33.7,100.175,30.5C102.466,27.3,103.611,24.5,105.902,24.5C108.192,24.5,109.338,46.5,111.628,46.5C113.919,46.5,115.064,34.1,117.355,28.5C119.646,22.9,120.791,18.5,123.082,18.5C125.373,18.5,126.518,21.9,128.809,24.5C131.099,27.1,132.245,29.1,134.536,31.5C136.826,33.9,137.972,36.5,140.262,36.5C142.553,36.5,143.698,36.3,145.989,35.5C148.28,34.7,149.425,32.5,151.716,32.5C154.007,32.5,155.152,35.5,157.443,35.5C159.733,35.5,160.879,22.5,163.169,22.5C165.46,22.5,166.605,36.5,168.896,43.5L168.896,38Z
M20,38L20,38.5C20,38.5,23.436,47.5,25.727,47.5C28.017,47.5,29.163,29.5,31.454,29.5C33.744,29.5,34.89,32.9,37.18,34.5C39.471,36.1,40.616,34.5,42.907,37.5C45.198,41.7,46.343,55.5,48.634,55.5L48.634,38Z
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: MendelG

67799325

Date: 2021-06-02 06:27:23
Score: 6.5
Natty: 4
Report link

ok‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎

Reasons:
  • No code block (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): ‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎‎
  • Low entropy (1):
  • Low reputation (1):
Posted by: Sam Jiggers

67797231

Date: 2021-06-02 00:47:56
Score: 0.5
Natty:
Report link

IIUC use groupby bfill:

df['REPEAT_AMOUNT'] = df.groupby('ID')['AMOUNT'].bfill()

df:

    ID  VARIABLE_DISTRIBUTION        DATE AMOUNT REPEAT_AMOUNT
0    1                     12  30-04-2021    NaN           100
1    1                     12  31-05-2021    NaN           100
2    1                     12  30-06-2021    NaN           100
3    1                     12  31-07-2021    100           100
4    1                     12  31-08-2021    NaN           150
5    1                     12  30-09-2021    NaN           150
6    1                     12  31-10-2021    NaN           150
7    1                     12  30-11-2021    NaN           150
8    1                     12  31-12-2021    NaN           150
9    1                     12  31-01-2022    NaN           150
10   1                     12  28-02-2022    NaN           150
11   1                     12  31-03-2022    NaN           150
12   1                     12  30-04-2022    NaN           150
13   1                     12  31-05-2022    NaN           150
14   1                     12  30-06-2022    NaN           150
15   1                     12  31-07-2022    150           150
16   2                      8  30-04-2021    NaN           200
17   2                      8  31-05-2021    200           200
18   2                      8  30-06-2021    NaN           300
19   2                      8  31-07-2021    NaN           300
20   2                      8  31-08-2021    NaN           300
21   2                      8  30-09-2021    NaN           300
22   2                      8  31-10-2021    NaN           300
23   2                      8  30-11-2021    NaN           300
24   2                      8  31-12-2021    NaN           300
25   2                      8  31-01-2022    300           300
26   2                      8  28-02-2022    NaN           NaN
27   2                      8  31-03-2022    NaN           NaN
28   2                      8  30-04-2022    NaN           NaN
29   2                      8  31-05-2022    NaN           NaN
30   2                      8  30-06-2022    NaN           NaN
31   2                      8  31-07-2022    NaN           NaN
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Henry Ecker

67796356

Date: 2021-06-01 22:48:52
Score: 6
Natty: 5.5
Report link

дякую за кончену пораду тепер все наново перевстановлювати і підкючати!

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Nazar Proton

67795821

Date: 2021-06-01 21:53:52
Score: 1
Natty:
Report link

Use in1d:

>>> X
array([[ 1.  ,  0.53],
       [ 2.  ,  0.72],
       [ 3.  ,  0.44],
       [ 4.  ,  0.35],
       [ 5.  ,  0.32],
       [ 6.  ,  0.14],
       [ 7.  ,  0.52],
       [ 8.  ,  0.4 ],
       [ 9.  ,  0.1 ],
       [10.  ,  0.1 ]])

>>> Y
array([[ 1.  ,  0.19],
       [ 2.  ,  0.96],
       [ 3.  ,  0.24],
       [ 4.  ,  0.44],
       [ 5.  ,  0.12],
       [ 6.  ,  0.91],
       [ 7.  ,  0.7 ],
       [ 8.  ,  0.54],
       [10.  ,  0.09]])
>>> X[np.in1d(X[:, 0], Y[:, 0])]
array([[ 1.  ,  0.53],
       [ 2.  ,  0.72],
       [ 3.  ,  0.44],
       [ 4.  ,  0.35],
       [ 5.  ,  0.32],
       [ 6.  ,  0.14],
       [ 7.  ,  0.52],
       [ 8.  ,  0.4 ],
       [10.  ,  0.1 ]])
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Corralien

67791399

Date: 2021-06-01 16:10:19
Score: 0.5
Natty:
Report link

If you've a nested list column like this:

df = pd.DataFrame({'col' : [[['6.65539026 -1.24900830'],
 ['6.65537977 -1.24882162'],
 ['6.65537977 -1.24882162'],
 ['6.65544653 -1.24888170'],
 ['6.65548515 -1.24828506'],
 ['6.65574646 -1.24843669'],
 ['6.65588522 -1.24853671'],
 ['6.65616179 -1.24875331'],
 ['6.65600824 -1.24891996'],
 ['6.65566158 -1.24909663'],
 ['6.65554523 -1.24906671']]]})

                                                                                                                                                                                                                                                                                              col
0  [[6.65539026 -1.24900830], [6.65537977 -1.24882162], [6.65537977 -1.24882162], [6.65544653 -1.24888170], [6.65548515 -1.24828506], [6.65574646 -1.24843669], [6.65588522 -1.24853671], [6.65616179 -1.24875331], [6.65600824 -1.24891996], [6.65566158 -1.24909663], [6.65554523 -1.24906671]]

Then you can try:

k = df.col.explode().str[0].str.split(' ')
df['col'] = k.groupby(k.index).agg(list)

OUTPUT:

                                                                                                                                                                                 col
0  [[6.65539026, -1.24900830], [6.65537977, -1.24882162], [6.65537977, -1.24882162], [6.65544653, -1.24888170], [6.65548515, -1.24828506], [6.65574646, -1.24843669], [6.65588522, -1.24853671], [6.65616179, -1.24875331], [6.65600824, -1.24891996], [6.65566158, -1.24909663], [6.65554523, -1.24906671]]
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-1):
Posted by: Nk03

67789261

Date: 2021-06-01 13:59:07
Score: 2.5
Natty:
Report link

If you want a dictionary that contains pair of month's starting date and ending date between your desired years, then here's how to get that.

start_year = int(input("Enter Starting Year: "))
end_year = int(input("Enter Ending Year: "))
import calendar
month_dict = {}
for x in range(start_year, end_year):
    for y in range(1, 13):
        if y < 10:
            start_date = '01'+'-'+'0'+str(y)+'-'+str(x)
            end_date = str(calendar.monthrange(x, y)[1])+'-'+'0'+str(y)+'-'+str(x)
            month_dict[start_date] = end_date
        else:
            start_date = '01'+'-'+str(y)+'-'+str(x)
            end_date = str(calendar.monthrange(x, y)[1])+'-'+str(y)+'-'+str(x)
            month_dict[start_date] = end_date

This gives the following output:

{'01-01-2000': '31-01-2000',
 '01-02-2000': '29-02-2000',
 '01-03-2000': '31-03-2000',
 '01-04-2000': '30-04-2000',
 '01-05-2000': '31-05-2000',
 '01-06-2000': '30-06-2000',
 '01-07-2000': '31-07-2000',
 '01-08-2000': '31-08-2000',
 '01-09-2000': '30-09-2000',
 '01-10-2000': '31-10-2000',
 '01-11-2000': '30-11-2000',
 '01-12-2000': '31-12-2000',
 '01-01-2001': '31-01-2001',
 '01-02-2001': '28-02-2001',
 '01-03-2001': '31-03-2001',
 '01-04-2001': '30-04-2001',
 '01-05-2001': '31-05-2001',
 '01-06-2001': '30-06-2001',
 '01-07-2001': '31-07-2001',
 '01-08-2001': '31-08-2001',
 '01-09-2001': '30-09-2001',
 '01-10-2001': '31-10-2001',
 '01-11-2001': '30-11-2001',
 '01-12-2001': '31-12-2001',
 '01-01-2002': '31-01-2002',
 '01-02-2002': '28-02-2002',
 '01-03-2002': '31-03-2002',
 '01-04-2002': '30-04-2002',
 '01-05-2002': '31-05-2002',
 '01-06-2002': '30-06-2002',
 '01-07-2002': '31-07-2002',
 '01-08-2002': '31-08-2002',
 '01-09-2002': '30-09-2002',
 '01-10-2002': '31-10-2002',
 '01-11-2002': '30-11-2002',
 '01-12-2002': '31-12-2002',
 '01-01-2003': '31-01-2003',
 '01-02-2003': '28-02-2003',
 '01-03-2003': '31-03-2003',
 '01-04-2003': '30-04-2003',
 '01-05-2003': '31-05-2003',
 '01-06-2003': '30-06-2003',
 '01-07-2003': '31-07-2003',
 '01-08-2003': '31-08-2003',
 '01-09-2003': '30-09-2003',
 '01-10-2003': '31-10-2003',
 '01-11-2003': '30-11-2003',
 '01-12-2003': '31-12-2003',
 '01-01-2004': '31-01-2004',
 '01-02-2004': '29-02-2004',
 '01-03-2004': '31-03-2004',
 '01-04-2004': '30-04-2004',
 '01-05-2004': '31-05-2004',
 '01-06-2004': '30-06-2004',
 '01-07-2004': '31-07-2004',
 '01-08-2004': '31-08-2004',
 '01-09-2004': '30-09-2004',
 '01-10-2004': '31-10-2004',
 '01-11-2004': '30-11-2004',
 '01-12-2004': '31-12-2004',
 '01-01-2005': '31-01-2005',
 '01-02-2005': '28-02-2005',
 '01-03-2005': '31-03-2005',
 '01-04-2005': '30-04-2005',
 '01-05-2005': '31-05-2005',
 '01-06-2005': '30-06-2005',
 '01-07-2005': '31-07-2005',
 '01-08-2005': '31-08-2005',
 '01-09-2005': '30-09-2005',
 '01-10-2005': '31-10-2005',
 '01-11-2005': '30-11-2005',
 '01-12-2005': '31-12-2005',
 '01-01-2006': '31-01-2006',
 '01-02-2006': '28-02-2006',
 '01-03-2006': '31-03-2006',
 '01-04-2006': '30-04-2006',
 '01-05-2006': '31-05-2006',
 '01-06-2006': '30-06-2006',
 '01-07-2006': '31-07-2006',
 '01-08-2006': '31-08-2006',
 '01-09-2006': '30-09-2006',
 '01-10-2006': '31-10-2006',
 '01-11-2006': '30-11-2006',
 '01-12-2006': '31-12-2006',
 '01-01-2007': '31-01-2007',
 '01-02-2007': '28-02-2007',
 '01-03-2007': '31-03-2007',
 '01-04-2007': '30-04-2007',
 '01-05-2007': '31-05-2007',
 '01-06-2007': '30-06-2007',
 '01-07-2007': '31-07-2007',
 '01-08-2007': '31-08-2007',
 '01-09-2007': '30-09-2007',
 '01-10-2007': '31-10-2007',
 '01-11-2007': '30-11-2007',
 '01-12-2007': '31-12-2007',
 '01-01-2008': '31-01-2008',
 '01-02-2008': '29-02-2008',
 '01-03-2008': '31-03-2008',
 '01-04-2008': '30-04-2008',
 '01-05-2008': '31-05-2008',
 '01-06-2008': '30-06-2008',
 '01-07-2008': '31-07-2008',
 '01-08-2008': '31-08-2008',
 '01-09-2008': '30-09-2008',
 '01-10-2008': '31-10-2008',
 '01-11-2008': '30-11-2008',
 '01-12-2008': '31-12-2008',
 '01-01-2009': '31-01-2009',
 '01-02-2009': '28-02-2009',
 '01-03-2009': '31-03-2009',
 '01-04-2009': '30-04-2009',
 '01-05-2009': '31-05-2009',
 '01-06-2009': '30-06-2009',
 '01-07-2009': '31-07-2009',
 '01-08-2009': '31-08-2009',
 '01-09-2009': '30-09-2009',
 '01-10-2009': '31-10-2009',
 '01-11-2009': '30-11-2009',
 '01-12-2009': '31-12-2009',
 '01-01-2010': '31-01-2010',
 '01-02-2010': '28-02-2010',
 '01-03-2010': '31-03-2010',
 '01-04-2010': '30-04-2010',
 '01-05-2010': '31-05-2010',
 '01-06-2010': '30-06-2010',
 '01-07-2010': '31-07-2010',
 '01-08-2010': '31-08-2010',
 '01-09-2010': '30-09-2010',
 '01-10-2010': '31-10-2010',
 '01-11-2010': '30-11-2010',
 '01-12-2010': '31-12-2010',
 '01-01-2011': '31-01-2011',
 '01-02-2011': '28-02-2011',
 '01-03-2011': '31-03-2011',
 '01-04-2011': '30-04-2011',
 '01-05-2011': '31-05-2011',
 '01-06-2011': '30-06-2011',
 '01-07-2011': '31-07-2011',
 '01-08-2011': '31-08-2011',
 '01-09-2011': '30-09-2011',
 '01-10-2011': '31-10-2011',
 '01-11-2011': '30-11-2011',
 '01-12-2011': '31-12-2011',
 '01-01-2012': '31-01-2012',
 '01-02-2012': '29-02-2012',
 '01-03-2012': '31-03-2012',
 '01-04-2012': '30-04-2012',
 '01-05-2012': '31-05-2012',
 '01-06-2012': '30-06-2012',
 '01-07-2012': '31-07-2012',
 '01-08-2012': '31-08-2012',
 '01-09-2012': '30-09-2012',
 '01-10-2012': '31-10-2012',
 '01-11-2012': '30-11-2012',
 '01-12-2012': '31-12-2012',
 '01-01-2013': '31-01-2013',
 '01-02-2013': '28-02-2013',
 '01-03-2013': '31-03-2013',
 '01-04-2013': '30-04-2013',
 '01-05-2013': '31-05-2013',
 '01-06-2013': '30-06-2013',
 '01-07-2013': '31-07-2013',
 '01-08-2013': '31-08-2013',
 '01-09-2013': '30-09-2013',
 '01-10-2013': '31-10-2013',
 '01-11-2013': '30-11-2013',
 '01-12-2013': '31-12-2013',
 '01-01-2014': '31-01-2014',
 '01-02-2014': '28-02-2014',
 '01-03-2014': '31-03-2014',
 '01-04-2014': '30-04-2014',
 '01-05-2014': '31-05-2014',
 '01-06-2014': '30-06-2014',
 '01-07-2014': '31-07-2014',
 '01-08-2014': '31-08-2014',
 '01-09-2014': '30-09-2014',
 '01-10-2014': '31-10-2014',
 '01-11-2014': '30-11-2014',
 '01-12-2014': '31-12-2014',
 '01-01-2015': '31-01-2015',
 '01-02-2015': '28-02-2015',
 '01-03-2015': '31-03-2015',
 '01-04-2015': '30-04-2015',
 '01-05-2015': '31-05-2015',
 '01-06-2015': '30-06-2015',
 '01-07-2015': '31-07-2015',
 '01-08-2015': '31-08-2015',
 '01-09-2015': '30-09-2015',
 '01-10-2015': '31-10-2015',
 '01-11-2015': '30-11-2015',
 '01-12-2015': '31-12-2015',
 '01-01-2016': '31-01-2016',
 '01-02-2016': '29-02-2016',
 '01-03-2016': '31-03-2016',
 '01-04-2016': '30-04-2016',
 '01-05-2016': '31-05-2016',
 '01-06-2016': '30-06-2016',
 '01-07-2016': '31-07-2016',
 '01-08-2016': '31-08-2016',
 '01-09-2016': '30-09-2016',
 '01-10-2016': '31-10-2016',
 '01-11-2016': '30-11-2016',
 '01-12-2016': '31-12-2016',
 '01-01-2017': '31-01-2017',
 '01-02-2017': '28-02-2017',
 '01-03-2017': '31-03-2017',
 '01-04-2017': '30-04-2017',
 '01-05-2017': '31-05-2017',
 '01-06-2017': '30-06-2017',
 '01-07-2017': '31-07-2017',
 '01-08-2017': '31-08-2017',
 '01-09-2017': '30-09-2017',
 '01-10-2017': '31-10-2017',
 '01-11-2017': '30-11-2017',
 '01-12-2017': '31-12-2017',
 '01-01-2018': '31-01-2018',
 '01-02-2018': '28-02-2018',
 '01-03-2018': '31-03-2018',
 '01-04-2018': '30-04-2018',
 '01-05-2018': '31-05-2018',
 '01-06-2018': '30-06-2018',
 '01-07-2018': '31-07-2018',
 '01-08-2018': '31-08-2018',
 '01-09-2018': '30-09-2018',
 '01-10-2018': '31-10-2018',
 '01-11-2018': '30-11-2018',
 '01-12-2018': '31-12-2018',
 '01-01-2019': '31-01-2019',
 '01-02-2019': '28-02-2019',
 '01-03-2019': '31-03-2019',
 '01-04-2019': '30-04-2019',
 '01-05-2019': '31-05-2019',
 '01-06-2019': '30-06-2019',
 '01-07-2019': '31-07-2019',
 '01-08-2019': '31-08-2019',
 '01-09-2019': '30-09-2019',
 '01-10-2019': '31-10-2019',
 '01-11-2019': '30-11-2019',
 '01-12-2019': '31-12-2019',
 '01-01-2020': '31-01-2020',
 '01-02-2020': '29-02-2020',
 '01-03-2020': '31-03-2020',
 '01-04-2020': '30-04-2020',
 '01-05-2020': '31-05-2020',
 '01-06-2020': '30-06-2020',
 '01-07-2020': '31-07-2020',
 '01-08-2020': '31-08-2020',
 '01-09-2020': '30-09-2020',
 '01-10-2020': '31-10-2020',
 '01-11-2020': '30-11-2020',
 '01-12-2020': '31-12-2020',
 '01-01-2021': '31-01-2021',
 '01-02-2021': '28-02-2021',
 '01-03-2021': '31-03-2021',
 '01-04-2021': '30-04-2021',
 '01-05-2021': '31-05-2021',
 '01-06-2021': '30-06-2021',
 '01-07-2021': '31-07-2021',
 '01-08-2021': '31-08-2021',
 '01-09-2021': '30-09-2021',
 '01-10-2021': '31-10-2021',
 '01-11-2021': '30-11-2021',
 '01-12-2021': '31-12-2021'}
Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Devesh Vijay

67780425

Date: 2021-05-31 22:38:19
Score: 8
Natty:
Report link

No...........................................;

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Has no white space (0.5):
  • No latin characters (3):
  • Filler text (0.5): ...........................................
  • Low entropy (1):
  • Low reputation (1):
Posted by: Dri372

67760645

Date: 2021-05-30 12:36:49
Score: 6
Natty:
Report link

الله ، هذا فقط يمكنك تخمين ما نشعر به في الداخل

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: Thiago Wesley

67759723

Date: 2021-05-30 10:43:45
Score: 7
Natty: 5.5
Report link

בדיקה בדיקה בדיקה שדג שדג שדג שדג שדג

Reasons:
  • Low length (2):
  • No code block (0.5):
  • Unregistered user (0.5):
  • No latin characters (3):
  • Low reputation (1):
Posted by: user16075294

67751809

Date: 2021-05-29 14:21:32
Score: 0.5
Natty:
Report link
$ awk -v OFS=',' '{$1=$1}1' file
0,12,0,12,1.0000
1,25,0,25,1.0000
2,14,0,14,1.0000
3,21,0,21,1.0000
4,31,0,31,1.0000
5,28,0,28,1.0000
6,16,0,16,1.0000
7,51,0,51,1.0000
8,26,0,26,1.0000
9,15,0,15,1.0000
10,26,0,26,1.0000
11,21,0,21,1.0000
12,14,0,14,1.0000
13,20,0,20,1.0000
14,34,0,34,1.0000
15,14,0,14,0.9950
16,15,0,15,0.9900
17,34,1,35,0.9851
18,19,1,20,0.9801
Reasons:
  • Has code block (-0.5):
  • No latin characters (3):
  • High reputation (-2):
Posted by: Ed Morton