从使用python/pandas分隔的数据中查找周期性

发布于 2025-02-13 17:12:39 字数 1957 浏览 0 评论 0原文

我正在为获取一些数据跟踪从图形计算器的特定症状到我可能能够找到某个问题的所有数据所需的所有步骤而苦苦挣扎,从而找到一些周期性,从而推断出潜在的因果关系。不幸的是,其中一种症状是脑雾...

我设法将计算器的数据从“假定的CSV文件”中获取,尽管看起来不像一个。它的格式是这样的,从进行转换的软件中:

0.25
0.5
1
2
2.5
2
1.5
1.5
...
...
...

我希望像

import pandas as pd
import numpy as np

df = pd.read_csv("L5.csv")
print(df.shape)

print(pd.infer_freq(df))

能做到的那样简单而简单,但是我什

(356, 1)
None

至无法分辨出形状是否意味着我有一个1D列表与之合作。如果有的话,print(pd.infer_freq(df))会给我我需要的东西吗?

任何帮助都非常感谢。

编辑完整数据如下所示:

0.25
0.5
1
2
2.5
2
1.5
1.5
2
2
2.5
2
2
2.5
2.5
2
2.5
2
2
2.5
2.5
2.5
2.5
2.5
1.75
3.25
2
2
2
2
2.5
2
3
2.5
2
2
1.5
1.5
2.25
3
2.5
2.75
2.5
1.5
2
2.5
2.25
1.75
3
2.25
2.5
2.75
2
2.25
2.25
3
2.25
2.25
1.25
1.5
1.25
2
2
2.5
2.5
2.25
1.25
1.5
2
2
2.25
3
2.75
2.25
2
2
1.75
1.75
1.75
2.5
2.5
2.5
2
2.75
2.75
2
2.5
3
2.5
2.75
2.75
3
2.5
3
2.75
2.75
2.5
2.5
2.25
2.25
2.5
2.75
2.5
2.5
2.5
2.5
3
2.5
2.25
2
3
2.75
3.25
2.5
2.75
3
3.25
2.5
2.5
2.75
2.75
2.75
2.5
3.25
3.5
2.75
4
3.75
2.5
3
2.25
2.25
1.75
1.5
1.5
1.75
1.5
3.5
2.5
3
2.75
2.75
2
1.5
1.25
2.25
2.5
2.75
3.5
3.25
2.25
2.75
2.75
3
2.75
2.5
3.25
2
1
1.5
2.5
3
2.75
3
3
3.25
2.75
2.75
3
2.75
2.25
3
2.5
2.5
2
1.75
2
1.25
1.5
2.5
2.75
3.5
3
2.75
3
3.25
3
3.25
3.25
3
2.75
2.75
2.75
3.25
2.5
2.5
2
1.5
2
2.25
3
3.25
2.75
2
1.75
1.5
2.25
3
2.25
2.75
2.75
3.5
2.75
2.75
2
2
1.5
2.75
2.5
3.5
3
2.25
1.5
1.75
1.75
1.75
2
2.25
2.75
3.25
2.5
3.5
2.5
3.25
3
2.5
2.5
2.75
3.25
2.5
2
2.75
3
2.75
3
2.25
3.25
2
2
2.75
2.75
2.5
3
3.25
3
3.5
3.25
2.75
2.75
2.75
2.25
3.25
3.25
2.25
2
1.75
2.25
2.5
2.75
2
2.75
3
3.5
3.25
3.5
3
3.25
2.5
3
3.25
2.5
2.5
2.75
2.75
3.25
2.5
2
3
2.25
3
3.75
3.5
3
2.25
1.75
2
1.75
2.25
3
2.5
1.5
1.5
1.75
2
3
3
2.25
2.5
2
2.5
3.25
2
2.5
3
2.75
3.25
3
3
3
2
2.25
2.75
3.25
2.75
3
2.25
2.5
2.25
1.5
1.5
2
1.5
1.75
1.5
2.5
2.5
3
2.75
3.25
3.25
3.25
2.5
2
2.75
3
1.75
3
1.75
2
2.5
1.5
2.5
3.25
2.5
3.25
3.25
3

I'm struggling with all the steps needed to get some data tracking a particular symptom from my graphics calculator to the point where I may be able so find some periodicity and thereby infer potential causal relationships. Unfortunately, one of the symptoms is brain fog...

I've managed to get the data from the calculator into "supposed csv file", although it doesn't look like one. It is formatted like so, from the software which did the conversion:

0.25
0.5
1
2
2.5
2
1.5
1.5
...
...
...

I was hoping something nice and simple like

import pandas as pd
import numpy as np

df = pd.read_csv("L5.csv")
print(df.shape)

print(pd.infer_freq(df))

Might do the trick, but I get

(356, 1)
None

I can't even tell at this point if the shape means I've got a 1D list to work with. And if I have, is something like print(pd.infer_freq(df)) going to give me what I need?

Any help much appreciated.

EDIT the full data is shown below:

0.25
0.5
1
2
2.5
2
1.5
1.5
2
2
2.5
2
2
2.5
2.5
2
2.5
2
2
2.5
2.5
2.5
2.5
2.5
1.75
3.25
2
2
2
2
2.5
2
3
2.5
2
2
1.5
1.5
2.25
3
2.5
2.75
2.5
1.5
2
2.5
2.25
1.75
3
2.25
2.5
2.75
2
2.25
2.25
3
2.25
2.25
1.25
1.5
1.25
2
2
2.5
2.5
2.25
1.25
1.5
2
2
2.25
3
2.75
2.25
2
2
1.75
1.75
1.75
2.5
2.5
2.5
2
2.75
2.75
2
2.5
3
2.5
2.75
2.75
3
2.5
3
2.75
2.75
2.5
2.5
2.25
2.25
2.5
2.75
2.5
2.5
2.5
2.5
3
2.5
2.25
2
3
2.75
3.25
2.5
2.75
3
3.25
2.5
2.5
2.75
2.75
2.75
2.5
3.25
3.5
2.75
4
3.75
2.5
3
2.25
2.25
1.75
1.5
1.5
1.75
1.5
3.5
2.5
3
2.75
2.75
2
1.5
1.25
2.25
2.5
2.75
3.5
3.25
2.25
2.75
2.75
3
2.75
2.5
3.25
2
1
1.5
2.5
3
2.75
3
3
3.25
2.75
2.75
3
2.75
2.25
3
2.5
2.5
2
1.75
2
1.25
1.5
2.5
2.75
3.5
3
2.75
3
3.25
3
3.25
3.25
3
2.75
2.75
2.75
3.25
2.5
2.5
2
1.5
2
2.25
3
3.25
2.75
2
1.75
1.5
2.25
3
2.25
2.75
2.75
3.5
2.75
2.75
2
2
1.5
2.75
2.5
3.5
3
2.25
1.5
1.75
1.75
1.75
2
2.25
2.75
3.25
2.5
3.5
2.5
3.25
3
2.5
2.5
2.75
3.25
2.5
2
2.75
3
2.75
3
2.25
3.25
2
2
2.75
2.75
2.5
3
3.25
3
3.5
3.25
2.75
2.75
2.75
2.25
3.25
3.25
2.25
2
1.75
2.25
2.5
2.75
2
2.75
3
3.5
3.25
3.5
3
3.25
2.5
3
3.25
2.5
2.5
2.75
2.75
3.25
2.5
2
3
2.25
3
3.75
3.5
3
2.25
1.75
2
1.75
2.25
3
2.5
1.5
1.5
1.75
2
3
3
2.25
2.5
2
2.5
3.25
2
2.5
3
2.75
3.25
3
3
3
2
2.25
2.75
3.25
2.75
3
2.25
2.5
2.25
1.5
1.5
2
1.5
1.75
1.5
2.5
2.5
3
2.75
3.25
3.25
3.25
2.5
2
2.75
3
1.75
3
1.75
2
2.5
1.5
2.5
3.25
2.5
3.25
3.25
3

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文