Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

python min date from dictionary

'''	df_dict:
index       an  bee
2015-07-02  2   5
2016-08-06  3   3
2016-09-13  2   1
2016-10-26  2   0
2016-11-02  7   2	'''

maxval = max(max(v.index) for k,v in df_dict.items())
minval = min(min(v.index) for k,v in df_dict.items())

print(maxval)
print(minval)

# Results:
2016-11-02 00:00:00
2015-07-02 00:00:00
Comment

PREVIOUS NEXT
Code Example
Python :: axes increase fonsize of values python 
Python :: REMOVE ALL ROWS FROM DATFRAME WGICH HAS DATA OLDER THAN 3 MONTHS PANDAS 
Python :: phone no validate 
Python :: gensim wordvector vocabulary list 
Python :: object creation using class constructor 
Python :: dataflair python 
Python :: plot true values vs actucal vales 
Python :: cv2 warpaffine rotate 
Python :: "json" is not defined 
Python :: mail.send_message flask not working, SSL == 465 
Python :: count upercase 
Python :: keras model predict list of input tensors 
Python :: https://raw.githubusercontent.com/tim-yao/lighthouse-ci/d32f465bb6cda08ded4ce25c88c43a3103e4940a/.browserslistrc 
Python :: how to create a calculator in python 
Python :: http response template 
Python :: save datetime day in seperate column 
Python :: insert string into middle of list python 
Python :: python strong type 
Python :: remove uppercase letters python 
Python :: The simplest way to start using doctest in python 
Python :: To fix this error install pymongo with the srv extra 
Python :: Iterate over several iterables in parallel 
Python :: c vs python speed 
Python :: Python Tkinter Scrollbar Widget Syntax 
Python :: python null check optional 
Python :: how to install apps in django 
Python :: updating lists 
Python :: django url wildcard 
Python :: Creating column based on existing column 
Python :: flask in colab ngrok error 
ADD CONTENT
Topic
Content
Source link
Name
7+7 =