新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧!

573 37
| 发表于 2023-3-22 15:19:38 | 显示全部楼层 |复制链接
chatGPT4发布了,喜欢凑热闹的当然不能错过啊。那么就让她来帮忙写个代码吧。据说GPT的代码能力有提高,具体如何 来实测一下就知道了。。。come on
先来个简单点的。直接让他写个如何在K线图找顶分型,先给出定义
然后开始撸代码吧,写得很快啊 基本上没有什么犹豫



新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
举报

收藏 1 点赞 1 评论 使用道具

精彩评论37

跳转到指定楼层
Abovethetop
D
2#
 楼主 | 发表于 2023-3-22 15:22:55 | 显示全部楼层
ctr v到 MT4中来编译一下
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
秒过啊。没有飘红,nice
举报

点赞 1 评论 使用道具

Abovethetop
D
3#
 楼主 | 发表于 2023-3-22 15:24:08 | 显示全部楼层
导入到K图看看 新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
果然用黄色箭头标出了顶分型
举报

点赞 评论 使用道具

Abovethetop
D
4#
 楼主 | 发表于 2023-3-22 15:28:05 | 显示全部楼层
这次回答也是很快 没有迟疑 继续给出了答案
写得怎么样,起码格式很规则吧,比我这个loser写的好多了吧
举报

点赞 评论 使用道具

Abovethetop
D
5#
 楼主 | 发表于 2023-3-22 15:29:05 | 显示全部楼层
好像排序错了点啊 sorry
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
举报

点赞 评论 使用道具

Abovethetop
D
6#
 楼主 | 发表于 2023-3-22 15:30:45 | 显示全部楼层

还行 就是有时候很卡 ,你懂的  是网络堵塞那种卡
举报

点赞 评论 使用道具

Abovethetop
D
7#
 楼主 | 发表于 2023-3-22 15:32:57 | 显示全部楼层
继续啊 ,顶底分型看来很easyl 没有难度
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
黄色顶分型,绿色底分型 很清晰吧
举报

点赞 评论 使用道具

Abovethetop
D
8#
 楼主 | 发表于 2023-3-22 15:34:30 | 显示全部楼层
movie 发表于 2023-3-22 15:33
你让它直接编写个圣杯试试

这个问题 是没有标准答案吧
举报

点赞 评论 使用道具

Abovethetop
D
9#
 楼主 | 发表于 2023-3-22 16:25:39 | 显示全部楼层
Jackiechiu 发表于 2023-3-22 15:50
來吧
發出來玩玩看啊

试试就试试
举报

点赞 评论 使用道具

Abovethetop
D
10#
 楼主 | 发表于 2023-3-22 16:26:51 | 显示全部楼层
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区 新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
你要的圣杯。。来了
举报

点赞 评论 使用道具

Abovethetop
D
11#
 楼主 | 发表于 2023-3-22 16:28:23 | 显示全部楼层
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
然而这没啥nuan用啊 说好的圣杯难道就是几句话
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
还是让他撸代码现实点
举报

点赞 评论 使用道具

Abovethetop
D
12#
 楼主 | 发表于 2023-3-22 16:30:09 | 显示全部楼层
期待 看看是什么样的。。
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区 新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
写得很规矩啊。。
//这是只测试哈 。。用于实盘亏损请自行负责。。不要怨我
举报

点赞 评论 使用道具

Abovethetop
D
13#
 楼主 | 发表于 2023-3-22 16:31:21 | 显示全部楼层
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区 新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
。。芭比Q  卡起了。。
举报

点赞 评论 使用道具

Abovethetop
D
14#
 楼主 | 发表于 2023-3-28 13:37:24 | 显示全部楼层
先科学上网,再注册 给钱升级plus
举报

点赞 评论 使用道具

Abovethetop
D
15#
 楼主 | 发表于 2023-3-28 13:39:12 | 显示全部楼层
来接点干货 随便写个能用的金叉 死叉玩玩
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
举报

点赞 评论 使用道具

Abovethetop
D
16#
 楼主 | 发表于 2023-3-28 13:40:13 | 显示全部楼层
要求很简单  难度不大 很快就写出来了
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
举报

点赞 评论 使用道具

Abovethetop
D
17#
 楼主 | 发表于 2023-3-28 13:43:18 | 显示全部楼层
测试一下 新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区 新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
问题没有 就是箭头太小了
让他改大一点
举报

点赞 评论 使用道具

Abovethetop
D
18#
 楼主 | 发表于 2023-3-28 13:43:52 | 显示全部楼层
//+------------------------------------------------------------------+
//|                                                    MACD_Arrows.mq4 |
//|                        Copyright 2023, MetaQuotes Software Corp. |
//|                                              https://www.mql5.com |
//+------------------------------------------------------------------+

#property copyright "2023, MetaQuotes Software Corp."
#property link      "https://www.mql5.com"
#property version   "1.00"
#property strict
#property indicator_separate_window
#property indicator_buffers 3
#property indicator_color1 Blue
#property indicator_color2 Red
#property indicator_color3 Green

double UpArrowBuffer[];
double DownArrowBuffer[];
double MACDBuffer[];

int OnInit()
  {
   SetIndexStyle(0, DRAW_LINE);
   SetIndexStyle(1, DRAW_ARROW);
   SetIndexStyle(2, DRAW_ARROW);
   SetIndexArrow(1, 241); // 241 is the code for an up arrow
   SetIndexArrow(2, 242); // 242 is the code for a down arrow
   SetIndexBuffer(0, MACDBuffer);
   SetIndexBuffer(1, UpArrowBuffer);
   SetIndexBuffer(2, DownArrowBuffer);
   IndicatorShortName("MACD Arrows");
   return(INIT_SUCCEEDED);
  }

int start()
  {
   int rates_total = Bars;
   int prev_calculated = IndicatorCounted();
   int limit = rates_total - prev_calculated;
   if(prev_calculated > 0)
      limit++;

   for(int i = 0; i < limit; i++)
     {
      int index = rates_total - i - 1;

      MACDBuffer[index] = iMACD(NULL, 0, 12, 26, 9, PRICE_CLOSE, MODE_MAIN, index);
      double diff = iMACD(NULL, 0, 12, 26, 9, PRICE_CLOSE, MODE_MAIN, index) - iMACD(NULL, 0, 12, 26, 9, PRICE_CLOSE, MODE_SIGNAL, index);
      double prev_diff = iMACD(NULL, 0, 12, 26, 9, PRICE_CLOSE, MODE_MAIN, index + 1) - iMACD(NULL, 0, 12, 26, 9, PRICE_CLOSE, MODE_SIGNAL, index + 1);

      UpArrowBuffer[index] = EMPTY_VALUE;
      DownArrowBuffer[index] = EMPTY_VALUE;

      if(MACDBuffer[index] < 0 && diff > 0 && prev_diff <= 0)
         UpArrowBuffer[index] = MACDBuffer[index] + 0.0001;

      if(MACDBuffer[index] > 0 && diff < 0 && prev_diff >= 0)
         DownArrowBuffer[index] = MACDBuffer[index] - 0.0001;
     }
   return(0);
  }
//+------------------------------------------------------------------+
这是源码
举报

点赞 评论 使用道具

Abovethetop
D
19#
 楼主 | 发表于 2023-3-28 13:44:46 | 显示全部楼层
是不是很标准呢 有没有比你写 得好.
反正比我写的标准点
举报

点赞 评论 使用道具

Abovethetop
D
20#
 楼主 | 发表于 2023-3-28 13:48:40 | 显示全部楼层
改大的那个对话没截图了,调整后的效果
新鲜出炉! chatGPT4帮我写代码!来凑个热闹吧! - EAHub外汇EA智能交易社区
改了其中几行
举报

点赞 评论 使用道具

12下一页
发新帖
EA交易
您需要登录后才可以评论 登录 | 立即注册