report

package
v0.3.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 11, 2021 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MAX_COMMENT_DEPTH = 8
	MAX_REPLY_LOOK    = 100
)
View Source
const (
	MinTotalScore = 10.0
)

Variables

View Source
var (
	TickerBlackList = []string{
		"USD",
		"YOLO",
		"DD",
		"RH",
		"HOLD",
		"IPO",
		"ITM",
		"OTM",
		"IMO",
		"CEO",
		"CFO",
		"CTO",
		"FTC",
		"FCC",
		"FEC",
		"MOON",
		"CAN",
		"EPS",
		"ATH",
		"ATL",
		"FOR",
		"GDP",
		"EDIT",
	}
	TickerRestrictedList = map[string]string{
		"A": "",
		"X": "",
		"U": "",
	}
)

Functions

func SortStockReports

func SortStockReports(stockReports []StockReport)

SortStockReports sorts the stockReports slice from greatest to least

Types

type CountResult

type CountResult struct {
	PostScore       int
	CommentScore    int
	TotalScore      float64
	PostMentions    int
	CommentMentions int
}

func (*CountResult) Add

func (c *CountResult) Add(c2 CountResult)

type StockReport

type StockReport struct {
	Stock stocks.Stock
	Count CountResult
}

func CountStockReferences

func CountStockReferences(tickers []stocks.Stock, posts []reddit.Post) ([]StockReport, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL