Skip to content

Instantly share code, notes, and snippets.

@kittisak-phetrungnapha
Created March 5, 2019 16:08
Show Gist options
  • Save kittisak-phetrungnapha/7d25943dbf0f2b64d5cd39990babcce5 to your computer and use it in GitHub Desktop.
Save kittisak-phetrungnapha/7d25943dbf0f2b64d5cd39990babcce5 to your computer and use it in GitHub Desktop.
appIdCondition = df['appId'].notnull()
dateCondition = df['date'].str.len() == 17
df = df[np.logical_and(appIdCondition, dateCondition)][['appId', 'date', 'dataSource']]
print(df)
print(df.count())
# Result
appId date dataSource
6 #10_Perfectly Clear 26:07:13:08:31:49 PlayStore_Random
13 #10_Fotocollage Bildbearbeitung 25:11:13:02:26:01 PlayStore_Random
20 #2_flipagram 11:01:14:06:00:35 PlayStore_Random
33 #10_Fotocollage Bildbearbeitung 14:01:14:16:46:44 PlayStore_Random
77 #3_skype 13:01:14:14:02:21 PlayStore_Random
128 #5_Pho to Lab PRO Fotobearbeitung 11:10:13:17:42:57 PlayStore_Random
149 #5_Pho to Lab PRO Fotobearbeitung 18:12:13:17:58:44 PlayStore_Random
163 #2_flipagram 01:01:14:06:38:29 PlayStore_Random
165 #6_MomentCam 30:12:13:05:41:47 PlayStore_Random
172 #10_Fotocollage Bildbearbeitung 10:01:14:17:45:10 PlayStore_Random
205 #3_Seitenmanager 17:11:13:17:31:34 PlayStore_Random
217 #7_Cymera - Camera & Photo Editor 25:12:13:06:53:35 PlayStore_Random
231 #6_Photo Studio PRO 09:01:14:00:28:40 PlayStore_Random
260 #9_subway_surfers 08:12:13:17:20:22 PlayStore_Random
262 #6_MomentCam 31:12:13:03:13:42 PlayStore_Random
264 #5_officesuite7 15:12:13:20:53:04 PlayStore_Random
268 #1_Camera Zoom FX 21:11:13:23:23:35 PlayStore_Random
272 #5_viber 14:01:14:11:47:04 PlayStore_Random
273 #2_flipagram 02:01:14:01:26:45 PlayStore_Random
276 #3_skype 12:01:14:15:37:06 PlayStore_Random
280 #8_gmx mail 08:01:13:16:18:28 PlayStore_Random
282 #9_Camera FV-5 17:11:13:09:20:24 PlayStore_Random
288 #1_Camera Zoom FX 24:12:13:18:23:21 PlayStore_Random
289 #1_quizduell 09:12:13:18:59:08 PlayStore_Random
290 #4_antivirus GRATIS 07:01:14:02:36:25 PlayStore_Random
291 #8_gmx mail 09:04:13:06:05:19 PlayStore_Random
294 #3_skype 11:01:14:23:52:32 PlayStore_Random
308 #1_Camera Zoom FX 25:04:13:06:49:10 PlayStore_Random
314 #6_stickman_soccer 29:11:13:18:50:29 PlayStore_Random
318 #4_sonic_dash 14:12:13:14:31:34 PlayStore_Random
.. ... ... ...
697 #3_skype 12:01:14:13:47:22 PlayStore_Random
698 #1_Camera Zoom FX 23:04:13:06:28:37 PlayStore_Random
700 #9_Perfect365 Gesichts-Make-Up 07:01:14:19:36:33 PlayStore_Random
701 #3_Seitenmanager 26:12:13:02:55:42 PlayStore_Random
702 #1_Camera Zoom FX 11:06:13:14:38:42 PlayStore_Random
704 #6_androidOpenOffice 02:12:13:13:44:04 PlayStore_Random
705 #8_XDA Premium 01:10:13:17:34:02 PlayStore_Random
706 #9_Perfect365 Gesichts-Make-Up 05:01:14:00:22:53 PlayStore_Random
709 #6_firefox 14:01:14:02:59:21 PlayStore_Random
710 #2_facebook messenger 12:01:14:10:08:23 PlayStore_Random
714 #2_traffic_racer 08:12:13:20:26:56 PlayStore_Random
715 #5_officesuite7 17:12:13:13:04:19 PlayStore_Random
716 #6_Antivirus PRO 18:12:12:20:37:37 PlayStore_Random
717 #4_antivirus GRATIS 04:01:14:08:45:27 PlayStore_Random
718 #2_flipagram 08:01:14:20:18:39 PlayStore_Random
719 #7_Cymera - Camera & Photo Editor 10:01:14:15:15:01 PlayStore_Random
722 #8_gmx mail 09:08:13:05:52:35 PlayStore_Random
723 #3_skype 13:01:14:10:06:33 PlayStore_Random
724 #10_line gratis anrufe 09:01:14:14:03:00 PlayStore_Random
725 #9_subway_surfers 14:12:13:14:35:36 PlayStore_Random
726 #1_Teamspeack 3 11:11:13:00:01:24 PlayStore_Random
727 #1_Teamspeack 3 11:11:13:00:01:24 PlayStore_Random
729 #6_androidOpenOffice 12:12:13:05:08:50 PlayStore_Random
730 #6_stickman_soccer 11:12:13:15:07:06 PlayStore_Random
732 #4_antivirus GRATIS 06:01:14:04:21:53 PlayStore_Random
733 #7_pou 14:12:13:19:24:10 PlayStore_Random
734 #3_Seitenmanager 28:12:13:03:14:04 PlayStore_Random
735 #3_ Wondershare PowerCam 19:12:13:23:55:54 PlayStore_Random
738 #7_pou 11:12:13:20:19:25 PlayStore_Random
739 #1_Teamspeack 3 07:10:13:18:55:32 PlayStore_Random
[161 rows x 3 columns]
appId 161
date 161
dataSource 161
dtype: int64
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment