mtcli 3.0.0.dev0__tar.gz → 3.0.0.dev1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (68) hide show
  1. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/PKG-INFO +1 -1
  2. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/commands/bars.py +21 -40
  3. mtcli-3.0.0.dev0/mtcli/models/model_chart.py → mtcli-3.0.0.dev1/mtcli/models/chart_model.py +4 -4
  4. mtcli-3.0.0.dev0/mtcli/views/view_close.py → mtcli-3.0.0.dev1/mtcli/views/close_view.py +2 -2
  5. mtcli-3.0.0.dev0/mtcli/views/view_full.py → mtcli-3.0.0.dev1/mtcli/views/full_view.py +4 -3
  6. mtcli-3.0.0.dev0/mtcli/views/view_high.py → mtcli-3.0.0.dev1/mtcli/views/high_view.py +2 -2
  7. mtcli-3.0.0.dev0/mtcli/views/view_low.py → mtcli-3.0.0.dev1/mtcli/views/low_view.py +2 -2
  8. mtcli-3.0.0.dev0/mtcli/views/view_min.py → mtcli-3.0.0.dev1/mtcli/views/min_view.py +2 -2
  9. mtcli-3.0.0.dev0/mtcli/views/view_open.py → mtcli-3.0.0.dev1/mtcli/views/open_view.py +2 -2
  10. mtcli-3.0.0.dev0/mtcli/views/view_ranges.py → mtcli-3.0.0.dev1/mtcli/views/ranges_view.py +2 -2
  11. mtcli-3.0.0.dev0/mtcli/views/view_rates.py → mtcli-3.0.0.dev1/mtcli/views/rates_view.py +2 -2
  12. mtcli-3.0.0.dev0/mtcli/views/view_vars.py → mtcli-3.0.0.dev1/mtcli/views/vars_view.py +2 -2
  13. mtcli-3.0.0.dev0/mtcli/views/view_volumes.py → mtcli-3.0.0.dev1/mtcli/views/volumes_view.py +2 -2
  14. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/pyproject.toml +1 -1
  15. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/LICENSE +0 -0
  16. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/README.md +0 -0
  17. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/__init__.py +0 -0
  18. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/commands/__init__.py +0 -0
  19. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/commands/conf.py +0 -0
  20. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/commands/logs.py +0 -0
  21. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/conecta.py +0 -0
  22. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/conf.py +0 -0
  23. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/data/__init__.py +0 -0
  24. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/data/base.py +0 -0
  25. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/data/csv.py +0 -0
  26. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/data/mt5.py +0 -0
  27. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/logger.py +0 -0
  28. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/models/__init__.py +0 -0
  29. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/models/bar_model.py +0 -0
  30. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/models/bars_model.py +0 -0
  31. /mtcli-3.0.0.dev0/mtcli/models/model_consecutive_bars.py → /mtcli-3.0.0.dev1/mtcli/models/consecutive_bars_model.py +0 -0
  32. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/models/model_conf.py +0 -0
  33. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/models/rates_model.py +0 -0
  34. /mtcli-3.0.0.dev0/mtcli/models/model_signals.py → /mtcli-3.0.0.dev1/mtcli/models/signals_model.py +0 -0
  35. /mtcli-3.0.0.dev0/mtcli/models/model_unconsecutive_bar.py → /mtcli-3.0.0.dev1/mtcli/models/unconsecutive_bar_model.py +0 -0
  36. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/mt.py +0 -0
  37. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugin.py +0 -0
  38. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/__init__.py +0 -0
  39. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/agressao/__init__.py +0 -0
  40. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/agressao/command.py +0 -0
  41. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/agressao/conf.py +0 -0
  42. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/agressao/models/__init__.py +0 -0
  43. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/agressao/models/model_agressao.py +0 -0
  44. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/agressao/views/__init__.py +0 -0
  45. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/agressao/views/view_agressao.py +0 -0
  46. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/media_movel/__init__.py +0 -0
  47. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/media_movel/command.py +0 -0
  48. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/media_movel/conf.py +0 -0
  49. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/media_movel/models/__init__.py +0 -0
  50. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/media_movel/models/model_media_movel.py +0 -0
  51. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/media_movel/tests/__init__.py +0 -0
  52. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/media_movel/tests/test_mm.py +0 -0
  53. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/media_movel/tests/test_model_media_movel.py +0 -0
  54. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/range_medio/__init__.py +0 -0
  55. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/range_medio/command.py +0 -0
  56. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/range_medio/conf.py +0 -0
  57. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/range_medio/models/__init__.py +0 -0
  58. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/range_medio/models/average_range_model.py +0 -0
  59. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/range_medio/tests/__init__.py +0 -0
  60. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/range_medio/tests/test_rm.py +0 -0
  61. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/volume_medio/__init__.py +0 -0
  62. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/volume_medio/command.py +0 -0
  63. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/volume_medio/conf.py +0 -0
  64. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/volume_medio/models/__init__.py +0 -0
  65. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/volume_medio/models/model_average_volume.py +0 -0
  66. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/volume_medio/tests/__init__.py +0 -0
  67. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/plugins/volume_medio/tests/test_vm.py +0 -0
  68. {mtcli-3.0.0.dev0 → mtcli-3.0.0.dev1}/mtcli/views/__init__.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: mtcli
3
- Version: 3.0.0.dev0
3
+ Version: 3.0.0.dev1
4
4
  Summary: Aplicativo CLI para exibir gráficos do MetaTrader 5 em texto acessível ao leitor de telas
5
5
  License: GPL-3.0
6
6
  Keywords: MetaTrader 5,trading,CLI
@@ -5,20 +5,19 @@ import click
5
5
  from mtcli import conf
6
6
  from mtcli.models.rates_model import RatesModel
7
7
  from mtcli.models.bars_model import BarsModel
8
- from mtcli.views import (
9
- view_close,
10
- view_full,
11
- view_high,
12
- view_low,
13
- view_min,
14
- view_open,
15
- view_ranges,
16
- view_rates,
17
- view_vars,
18
- view_volumes,
19
- )
8
+ from mtcli.views.full_view import FullView
9
+ from mtcli.views.min_view import MinView
10
+ from mtcli.views.ranges_view import RangesView
11
+ from mtcli.views.volumes_view import VolumesView
12
+ from mtcli.views.vars_view import VarsView
13
+ from mtcli.views.rates_view import RatesView
14
+ from mtcli.views.open_view import OpenView
15
+ from mtcli.views.high_view import HighView
16
+ from mtcli.views.low_view import LowView
17
+ from mtcli.views.close_view import CloseView
20
18
  from mtcli.logger import setup_logger
21
19
 
20
+
22
21
  logger = setup_logger("mtcli") # Cria o logger
23
22
 
24
23
 
@@ -96,45 +95,27 @@ def bars(symbol, view, period, count, date, numerator, show_date, volume):
96
95
  bars = BarsModel(rates, date).get_bars()
97
96
  views = []
98
97
  if view in ["m", "ch", "hl"]: # máximas e mínimas
99
- views = view_min.MinView(
100
- bars, count, period, date, numerator, show_date
101
- ).views()
98
+ views = MinView(bars, count, period, date, numerator, show_date).views()
102
99
  elif view in ["r", "range"]: # ranges
103
- views = view_ranges.RangesView(
104
- bars, count, period, date, numerator, show_date
105
- ).views()
100
+ views = RangesView(bars, count, period, date, numerator, show_date).views()
106
101
  elif view in ["oh", "ohlc"]: # OHLC
107
- views = view_rates.RatesView(
108
- bars, count, period, date, numerator, show_date
109
- ).views()
102
+ views = RatesView(bars, count, period, date, numerator, show_date).views()
110
103
  elif view in ["va", "percentual"]: # variações percentuais
111
- views = view_vars.VarsView(
112
- bars, count, period, date, numerator, show_date
113
- ).views()
104
+ views = VarsView(bars, count, period, date, numerator, show_date).views()
114
105
  elif view in ["o", "open"]: # abertura
115
- views = view_open.OpenView(
116
- bars, count, period, date, numerator, show_date
117
- ).views()
106
+ views = OpenView(bars, count, period, date, numerator, show_date).views()
118
107
  elif view in ["h", "high"]: # máximas
119
- views = view_high.HighView(
120
- bars, count, period, date, numerator, show_date
121
- ).views()
108
+ views = HighView(bars, count, period, date, numerator, show_date).views()
122
109
  elif view in ["l", "low"]: # mínimas
123
- views = view_low.LowView(
124
- bars, count, period, date, numerator, show_date
125
- ).views()
110
+ views = LowView(bars, count, period, date, numerator, show_date).views()
126
111
  elif view in ["c", "close"]: # fechamentos
127
- views = view_close.CloseView(
128
- bars, count, period, date, numerator, show_date
129
- ).views()
112
+ views = CloseView(bars, count, period, date, numerator, show_date).views()
130
113
  elif view in ["v", "volume"]: # volumes
131
- views = view_volumes.VolumesView(
114
+ views = VolumesView(
132
115
  bars, count, period, date, numerator, show_date, volume
133
116
  ).views()
134
117
  else: # completo
135
- views = view_full.FullView(
136
- bars, count, period, date, numerator, show_date
137
- ).views()
118
+ views = FullView(bars, count, period, date, numerator, show_date).views()
138
119
  if views:
139
120
  for view in views:
140
121
  click.echo(view)
@@ -1,6 +1,6 @@
1
1
  """Módulo da classe model do gráfico."""
2
2
 
3
- from mtcli.models import model_consecutive_bars
3
+ from mtcli.models.consecutive_bars_model import ConsecutiveBarsModel
4
4
 
5
5
 
6
6
  class ChartModel:
@@ -39,7 +39,7 @@ class ChartModel:
39
39
  lows.append(bar.low)
40
40
  volumes.append(bar.volume)
41
41
  if len(lows) == 2:
42
- consecutive = model_consecutive_bars.ConsecutiveBarsModel(
42
+ consecutive = ConsecutiveBarsModel(
43
43
  bodys, opens, closes, highs, lows, volumes
44
44
  )
45
45
  sequencia = consecutive.sequencia()
@@ -71,7 +71,7 @@ class ChartModel:
71
71
  lows.append(bar.low)
72
72
  volumes.append(bar.volume)
73
73
  if len(lows) == 2:
74
- consecutive = model_consecutive_bars.ConsecutiveBarsModel(
74
+ consecutive = ConsecutiveBarsModel(
75
75
  bodys, opens, closes, highs, lows, volumes
76
76
  )
77
77
  gap = consecutive.gap()
@@ -107,7 +107,7 @@ class ChartModel:
107
107
  else volumes.append(bar.volume_real)
108
108
  )
109
109
  if len(lows) == 2:
110
- consecutive = model_consecutive_bars.ConsecutiveBarsModel(
110
+ consecutive = ConsecutiveBarsModel(
111
111
  bodys, opens, closes, highs, lows, volumes
112
112
  )
113
113
  sequencia = consecutive.volume()
@@ -1,7 +1,7 @@
1
1
  """Módulo da classe da view dos fechamentos."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class CloseView:
@@ -16,7 +16,7 @@ class CloseView:
16
16
  self.date = date
17
17
  self.numerator = numerator
18
18
  self.show_date = show_date
19
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
19
+ self.chart = ChartModel(bars, len(bars), count, date)
20
20
  self.bars = bars[-count:]
21
21
 
22
22
  def views(self):
@@ -1,7 +1,8 @@
1
1
  """Módulo da view completa."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart, model_unconsecutive_bar
4
+ from mtcli.models.chart_model import ChartModel
5
+ from mtcli.models.unconsecutive_bar_model import UnconsecutiveBarModel
5
6
 
6
7
 
7
8
  class FullView:
@@ -15,7 +16,7 @@ class FullView:
15
16
  self.date = date
16
17
  self.numerator = numerator
17
18
  self.show_date = show_date
18
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
19
+ self.chart = ChartModel(bars, len(bars), count, date)
19
20
  self.bars = bars[-count:]
20
21
 
21
22
  def views(self):
@@ -28,7 +29,7 @@ class FullView:
28
29
  zip(self.bars, gaps, sequencias), start=1
29
30
  ):
30
31
  n += 1
31
- barra = model_unconsecutive_bar.UnconsecutiveBarModel(
32
+ barra = UnconsecutiveBarModel(
32
33
  bar.body, bar.top, bar.bottom, bar.close, bar.medium_point
33
34
  )
34
35
  rompimento = barra.get_breakout()
@@ -1,7 +1,7 @@
1
1
  """Módulo da classe da view das máximas."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class HighView:
@@ -16,7 +16,7 @@ class HighView:
16
16
  self.date = date
17
17
  self.numerator = numerator
18
18
  self.show_date = show_date
19
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
19
+ self.chart = ChartModel(bars, len(bars), count, date)
20
20
  self.bars = bars[-count:]
21
21
 
22
22
  def views(self):
@@ -1,7 +1,7 @@
1
1
  """Módulo da classe da view de mínimas."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class LowView:
@@ -16,7 +16,7 @@ class LowView:
16
16
  self.date = date
17
17
  self.numerator = numerator
18
18
  self.show_date = show_date
19
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
19
+ self.chart = ChartModel(bars, len(bars), count, date)
20
20
  self.bars = bars[-count:]
21
21
 
22
22
  def views(self):
@@ -1,7 +1,7 @@
1
1
  """Módulo da classe da view mínima."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class MinView:
@@ -15,7 +15,7 @@ class MinView:
15
15
  self.date = date
16
16
  self.numerator = numerator
17
17
  self.show_date = show_date
18
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
18
+ self.chart = ChartModel(bars, len(bars), count, date)
19
19
  self.bars = bars[-count:]
20
20
 
21
21
  def views(self):
@@ -1,7 +1,7 @@
1
1
  """Módulo da classe da view das aberturas."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class OpenView:
@@ -16,7 +16,7 @@ class OpenView:
16
16
  self.date = date
17
17
  self.numerator = numerator
18
18
  self.show_date = show_date
19
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
19
+ self.chart = ChartModel(bars, len(bars), count, date)
20
20
  self.bars = bars[-count:]
21
21
 
22
22
  def views(self):
@@ -1,7 +1,7 @@
1
1
  """Módulo da classe da view dos ranges."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class RangesView:
@@ -16,7 +16,7 @@ class RangesView:
16
16
  self.date = date
17
17
  self.numerator = numerator
18
18
  self.show_date = show_date
19
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
19
+ self.chart = ChartModel(bars, len(bars), count, date)
20
20
  self.bars = bars[-count:]
21
21
 
22
22
  def views(self):
@@ -1,7 +1,7 @@
1
1
  """Módulo da view das cotações OHLC."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class RatesView:
@@ -16,7 +16,7 @@ class RatesView:
16
16
  self.date = date
17
17
  self.numerator = numerator
18
18
  self.show_date = show_date
19
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
19
+ self.chart = ChartModel(bars, len(bars), count, date)
20
20
  self.bars = bars[-count:]
21
21
 
22
22
  def views(self):
@@ -1,7 +1,7 @@
1
1
  """Módulo da classe da view de variações percentuais."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class VarsView:
@@ -16,7 +16,7 @@ class VarsView:
16
16
  self.date = date
17
17
  self.numerator = numerator
18
18
  self.show_date = show_date
19
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
19
+ self.chart = ChartModel(bars, len(bars), count, date)
20
20
  self.bars = bars[-count:]
21
21
 
22
22
  def views(self):
@@ -1,7 +1,7 @@
1
1
  """Módulo da classe da view de volumes."""
2
2
 
3
3
  from mtcli import conf
4
- from mtcli.models import model_chart
4
+ from mtcli.models.chart_model import ChartModel
5
5
 
6
6
 
7
7
  class VolumesView:
@@ -24,7 +24,7 @@ class VolumesView:
24
24
  self.numerator = numerator
25
25
  self.show_date = show_date
26
26
  self.volume = volume
27
- self.chart = model_chart.ChartModel(bars, len(bars), count, date)
27
+ self.chart = ChartModel(bars, len(bars), count, date)
28
28
  self.bars = bars[-count:]
29
29
 
30
30
  def views(self):
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "mtcli"
3
- version = "3.0.0.dev0"
3
+ version = "3.0.0.dev1"
4
4
  description = "Aplicativo CLI para exibir gráficos do MetaTrader 5 em texto acessível ao leitor de telas"
5
5
  authors = [
6
6
  {name = "Valmir França da Silva",email = "vfranca3@gmail.com"}
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes