DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

Split Date&Time channel to Date channel and Time channel

Solved!
Go to solution

Hello

 

In order to make a 3d graph with an X axis corresponding to time, Y to date and Z to temperature, I want to split a date/time channel into two channels (1 date channel and one time channel) .

How can I do this in Diadem? as a script?

Thank you for your ideas and help.

 

VGEIEBau_0-1611819713426.png

 

0 Kudos
Message 1 of 8
(1,885 Views)

Hi VGEIEBau,

 

If you want to make a graph in DIAdem, you DON'T want separate Date and Time channels.  Are you wanting to send these data columns outside DIAdem to make the graph?  What is the undesirable effect you see when you use the DateTime channel to define the X axis of your graph?  You can modify the display of the X axis values to just show Date or Time values even though the X-channel contains DateTime values, for instance.

 

Brad Turpin

Principal Technical Support Engineer

NI

0 Kudos
Message 2 of 8
(1,849 Views)

Hi Brad,

 

Thank you for your answer.

I want to analyze/visualize the data in diadem. If possible in a 3d graph. who the X axe values are the day in format DD.MM.YYY, the Y axe are the time in HH:MM and the Z values the temperature of channel 1.

I tried to visualize the data in 3D graph like your recommendation.

I obtain something like that.

VGEIEBau_0-1612160972479.png

 

The formatting of the y axes is not good.

 

 

I want to obtain this kind of graph.

VGEIEBau_1-1612161588539.png

 

regards

 

0 Kudos
Message 3 of 8
(1,820 Views)

Hi Brad,

 

My goal is to visualize my data like this graph

VGEIEBau_0-1612165024129.png

 

With my measurement file if I create a 3d graph with X axes the date&time channel, Y axes also date&time channel and Z axes my temperature I obtain this

 

VGEIEBau_1-1612165166564.png

How can i format the Y axes to have just the time (not just show the time )

 

VGEIEBau_2-1612165360112.png

 

That's why I asked the question how to create a new channel that contains only the time from the date and time channel.

 

regards

0 Kudos
Message 4 of 8
(1,825 Views)

I found an old forum discussion regarding the issue. Is this helpful to you? 

0 Kudos
Message 5 of 8
(1,808 Views)

Hi Vardanium,

 

No it is not exactly what i need.

 

i "just" need to write a script to split the date&time into two new column with date and time 

something like this:

Original File

Timestamp Record
03.12.2020 15:30:00.0000 0
03.12.2020 16:00:00.0000 1

 

New File

Timestamp Date Time Record
03.12.2020 15:30:00.0000 03.12.2020 15:30:00.0000 0
03.12.2020 16:00:00.0000 03.12.2020 16:00:00.0000 1

 

thank you

 

0 Kudos
Message 6 of 8
(1,797 Views)

Hi VGEIEBau,

 

You are right, for that 3D graph you do need to create a copy of the "Datetime" channel that only copies over the time values, not the date values.  I'm attaching a VBScript that does this using the Calculate() command and the RTT() and TTR() functions.  I'm also attaching a REPORT layout that shows the results in a graph similar to the one you posted.

 

You could do something similar to strip away the time content from the original "Datetime" channel, but I don't think that's necessary-- the time content will be lost in the display resolution of the Y axis in your proposed graph.

 

See what you think,

Brad Turpin

Principal Technical Support Engineer

NI

0 Kudos
Message 7 of 8
(1,786 Views)
Solution
Accepted by topic author VGEIEBau

Hi Brad,

 

Thank you so much for your help! It is exactly what I want.

 

I copy your script, define the variable and it works !

The diagram looks so

VGEIEBau_0-1612422556943.png

 

I just need to find how to set the interval of the Z legend but that is a details.

Thanks a lot Brad.

 

0 Kudos
Message 8 of 8
(1,774 Views)