Home > By category > Scripts >Development Tools > DateStr2Num



DateStr2Num

  • Downloads: 
  • Views: 
  • Rating:

DATESTR2NUM - Fast conversion of DATESTR to DATENUM

The builtin DATENUM command is very powerful, but if the input is known to be valid and formatted exactly, a specific MEX can be much faster:
For single strings DateStr2Num takes <1% of the processing time of DATENUM (even with specified date format), for a {1 x 10000} cell string, DateStr2Num needs 0.17% to 2.7% of the DATENUM time. (Matlab 2009a, MSVC 2008 using SSE2 optimization).

D = DateStr2Num(S, F)
INPUT:
S: String or cell string in DATESTR(F) format.
In opposite to DATENUM the validity of the input string is *not* checked,
e.g. if month is in [1:12] and hour in [0:23].
F: Integer number defining the input format. Accepted:
0: 'dd-mmm-yyyy HH:MM:SS' 01-Mar-2000 15:45:17
1: 'dd-mmm-yyyy' 01-Mar-2000
29: 'yyyy-mm-dd' 2000-03-01
30: 'yyyymmddTHHMMSS' 20000301T154517
31: 'yyyy-mm-dd HH:MM:SS' 2000-03-01 15:45:17
300: 'yyyymmddTHHMMSS.FFF'

OUTPUT:
D: Serial date number.

EXAMPLE:
C = {'2010-06-29 21:59:13', '2010-06-29 21:59:13'};
D = DateStr2Num(C, 31)
>> [734318.916122685, 734318.916122685]
Equivalent Matlab command (but a column vector is replied ever):
D = datenum(C, 'yyyy-mm-dd HH:MM:SS')

Precompiled Mex files: http://www.n-simon.de/mex

Tested: Matlab 6.5, 7.7, 7.8, 32bit, WinXP
Compiler: LCC 2.4/3.8, BCC 5.5, Open Watcom 1.8, MSVC 2008
Compatibility to MacOS, Linux, 64 bit is assumed, but not tested.

See also: DateConvert (Jan Simon)
http://www.mathworks.com/matlabcentral/fileexchange/25594

Free download from Shareware Connection - DATESTR2NUM - Fast conversion of DATESTR to DATENUM

Publisher: Jan Simon | License: Shareware
Version: 1.0 | Size: 10 KB | Platform: Matlab, Scripts
Released Date: 09-01-2013 | Rating: 0 | Title: DateStr2Num

Author Url: http://www.mathworks.com
Program Info Url: http://www.mathworks.com
Download Url: http://www.mathworks.com/matlabcentral/fx_files/28093/2/DateStr2Num_29Mar2011.zip

More downloads from DateStr2Num publisher Jan Simon:

ScaleTime - ScaleTime - fast linear matrix interpolation

FilterM - FilterM, FiltFiltM: Fast digital filter

strncmpr - Compare last N chars of strings or cell strings

Patch FILTFILT - If applied to a matrix, the function FILTFILT (Signal Processing Toolbox) calls itself recursively for each column.

fSGolayFilt - fSGolayFilt is a fast polynomial smoothing filter for uniformly spaced signals

DateStr2Num keywords:
DateStr2Num related downloads:

Serial Interface - Serial Interface provides you with a simple method for communicating with micro-controllers over a COM port.

Emulare - Emulare is an emulator for the Arduino Duemilanove.

ssc32 servo controller - Tcl/Tk interface for the SSC-32 servo controller.

Webuino - Arduino simulator to be used for verification of sketches.

Eltima Serial Port Monitor - Serial Port Monitor is a professional application for monitoring serial data exchange between serial devices and any Windows application. Serial Port Monitor comprises advanced features to display, log and analyze all serial port activity in a system

Shareware Connection periodically updates pricing and software information of 'DateStr2Num' from company source 'Jan Simon' , so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft,  Using 'DateStr2Num' crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of DateStr2Num.

New Reviews

WebAcappella - Web design sector has witnessed several trends and technological innovations affect website development in big ways. With time, designing websites has become easier. Nowadays, you can find web design software that nearly eliminates the need to ...

Trend Micro HouseCall - With time, PC users find it increasingly difficult to keep their systems free of malware and rogue apps, despite using latest and feature packed security software. This is mostly owing to the evolving nature of malware and newer types of ...

Bolide Movie Creator - Not many PC users ventured into editing video clips even a few years back. It was a task reserved for studio setups and professionals. However, emergence of mobile video recording devices, access to internet has changed things in recent times. ...

Dragon NaturallySpeaking Standard - No matter what type of computer you use, it becomes necessary to use keyboard for typing. This is the case with average home users as well as network administrators working in professional setups. Would not it be nice if you could give your hands ...

MacCleanse - Macs are known for their multitasking prowess and near perfect performance over other type of computers. However, after prolonged usage a Mac can also run slower than usual. In such situations, you can try third party clean up and maintenance ...

F-Secure Online Scanner - The menace of malware and various online threats have grown by leaps and bound in recent times. You no longer can stay assured after installing a regular malware cleaner or antivirus suite like earlier. Security conscious PC users often resort to ...

Screenshot Captor - Nowadays, a lot of Windows users need to take screenshots for professional and personal usage needs. It may be required to share an interesting image from web site or part of web pages with friends, making tutorials etc. However, freeware screen ...

Pixelmator - There is no denying the fact that Mac users are often left with fewer third party app choices than those who use Windows based PCs. However, when it comes to imaging, the situation is a little better. If you want a versatile image editor for Mac ...

SyncMate - Just like windows users, Macintosh users also need to sync their data with myriads of other devices and other Macs. It is possible to use Apple’s much touted iCloud to sync a Mac with other iOS based devices but that may not fit ...

DVDFab DVD Copy - While a lot of computer users are switching from optical media to external and cloud storage services, a section of them still counts on DVD for storage and movie watching. At times it also becomes necessary to copy those DVDs that are getting ...




New Downloads

Facebook Page Publish

"Facebook Page Publish"
publishes your blog posts to
the wall of your Facebook
profile, page or application

arkavis sidebar plugin

arkavis.de provides a way for
easily hundreds of games in
your WordPress automatically
integrate and apply new games.

Email Input Filter

Email Input Filter converts
email style markup into web
friendly format.

HornetsEye - Ruby Computer
Vision Lib

Video processing and computer
vision library for GNU/Linux
offering interfaces to do
image- and video-I/O with ...

MATLAB Contest - Protein

The sixth MATLAB Programming
Contest, Protein, will run
from November 6-13, 2002.

Model Replay

These MATLAB files serve as a
graphical user interface for
using the APMonitor moving
horizon estimation (MHE)
feature

ASPTemplate

ASPTemplate is an ASP/ASPX
HTML template engine.

Organic Groups - Multiple
Mandatory Groups by Role

Looking for co-maintainer. See
message in issue queue.

Flood Fill

The flood fill will alter all
values of 0 to one flood
filling from a start point
(xc,yc)

Image Noise Reduction by
Local Statistics

Reduce image noise by
measuring local pixel
statistics and remapping
intensities.

Easy PHP News Module

Easy PHP News Module (EPNM),
is a simple script to easily
add and remove content or news
to a website

matrandbin

This file generates a matrix
of 'n' (rxc) random numbers
(0's & 1's) with a binomial
distribution (randomized
binomial ...