全部版块 我的主页
论坛 数据科学与人工智能 数据分析与数据科学 SPSS论坛
17474 14
2007-11-01

excel中的日期型是这样的yyyy-mm-dd hh:mm,导入spss中怎么也不识别,我已经在spss中改成了date型了,还有时间类型hh:mm,也出现同样的问题。

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2007-11-2 09:50:00

着急啊,高手快帮帮忙啊

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2007-11-2 11:29:00
SPSS has date and date-time formats to read most common date representations; use them with the NUMBER function, since SPSS dates are numeric variables. If you don't have a format that SPSS will read, you can convert it with string commands.

Then, give the new variables any SPSS date or date-time format you want. The formats affect only the *display* of these variables, not their underlying values(*).You can then use DATEDIFF. Or, simply subtract the values; the difference of two SPSS date or date-time variables are in seconds.

(*) "Internally, all date format variables are stored as the number of seconds from 0 hours, 0 minutes, and 0 seconds of Oct. 14, 1582." - SPSS 15 Command Syntax Reference, p. 47.
<script></script>

[此贴子已经被作者于2007-11-2 11:31:21编辑过]

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2007-11-2 23:04:00

英文水平太差,楼上的看不懂.

我前段时间也遇见到这个问题,怎么也找不到方法,

后来就把他变成date和time两个变量就没有问题了。

如有高手请赐教阿。不胜感激!

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2007-11-2 23:04:00

英文水平太差,楼上的看不懂.

我前段时间也遇见到这个问题,怎么也找不到方法,

后来就把他变成date和time两个变量就没有问题了。

如有高手请赐教阿。不胜感激!

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2007-11-6 18:24:00
你先把excel导成文本,再导进spss,但要全文本的导进去,这样可以了!
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

点击查看更多内容…
相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群