{"id":15662791,"url":"https://github.com/sandertv/go-formula","last_synced_at":"2025-04-27T06:51:31.812Z","repository":{"id":57535611,"uuid":"174682294","full_name":"Sandertv/go-formula","owner":"Sandertv","description":"A go package for simple formula parsing and evaluation","archived":false,"fork":false,"pushed_at":"2020-09-02T09:55:59.000Z","size":47,"stargazers_count":18,"open_issues_count":1,"forks_count":4,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-30T08:32:11.216Z","etag":null,"topics":["evaluate","formula","golang"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Sandertv.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-03-09T10:54:34.000Z","updated_at":"2024-11-27T09:21:39.000Z","dependencies_parsed_at":"2022-08-29T00:41:00.844Z","dependency_job_id":null,"html_url":"https://github.com/Sandertv/go-formula","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sandertv%2Fgo-formula","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sandertv%2Fgo-formula/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sandertv%2Fgo-formula/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sandertv%2Fgo-formula/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Sandertv","download_url":"https://codeload.github.com/Sandertv/go-formula/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251099735,"owners_count":21536153,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["evaluate","formula","golang"],"created_at":"2024-10-03T13:34:33.694Z","updated_at":"2025-04-27T06:51:31.792Z","avatar_url":"https://github.com/Sandertv.png","language":"Go","readme":"# go-formula [![GoDoc](http://godoc.org/github.com/Sandertv/go-formula?status.svg)](https://godoc.org/github.com/Sandertv/go-formula/v2)\nA simple and fast formula parser and evaluator.\n\n## Getting Started\n\n### Usage\nFormulas may be parsed using the formula.New() function. The function returns a formula that may be evaluated\nan unlimited amount of times. Note that parsing formulas is generally heavier than evaluating them, so it is\nrecommended to parse once and evaluate the same formula multiple times where applicable.\n\n```go\npackage main\n\nimport (\n\t\"github.com/sandertv/go-formula/v2\"\n\t\"log\"\n)\n\nfunc main() {\n    f, err := formula.New(\"17*x + pow(z*3, 3)\")\n    if err != nil {\n        log.Print(err)\n        return\n    }\n    x := formula.Var(\"x\", 4.5)\n    z := formula.Var(\"z\", 5)\n    log.Printf(\"Formula output: %v\", f.MustEval(x, z))\n}\n```\n\n### Documentation\nhttps://godoc.org/github.com/Sandertv/go-formula/v2","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsandertv%2Fgo-formula","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsandertv%2Fgo-formula","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsandertv%2Fgo-formula/lists"}