{
  "_id": "6ad1d5e8d3c80a766859c1a6",
  "Package": "modelc",
  "Title": "A Linear Model to 'SQL' Compiler",
  "Version": "1.0.0.0",
  "Authors@R": "person(\"Sparkfish Analytics\", role=c(\"cph\"))\nperson(given = \"Hugo\", family = \"Saavedra\", email = \"analytics+hugo@sparkfish.com\", role = c(\"aut\", \"cre\"))",
  "Description": "This is a cross-platform linear model to 'SQL' compiler.\nIt generates 'SQL' from linear and generalized linear models.\nIts interface consists of a single function, modelc(), which\ntakes the output of lm() or glm() functions (or any object\nwhich has the same signature) and outputs a 'SQL' character\nvector representing the predictions on the scale of the\nresponse variable as described in Dunn & Smith (2018)\n<doi:10.1007/978-1-4419-0118-7> and originating in Nelder &\nWedderburn (1972) <doi:10.2307/2344614>. The resultant 'SQL'\ncan be included in a 'SELECT' statement and returns output\nsimilar to that of the glm.predict() or lm.predict()\npredictions, assuming numeric types are represented in the\ndatabase using sufficient precision. Currently log and identity\nlink functions are supported.",
  "License": "MIT + file LICENSE",
  "URL": "https://github.com/sparkfish/modelc",
  "BugReports": "https://github.com/sparkfish/modelc/issues",
  "Encoding": "UTF-8",
  "RoxygenNote": "7.1.0",
  "Repository": "https://sparkfish.r-universe.dev",
  "Date/Publication": "2020-06-18 19:06:14 UTC",
  "RemoteUrl": "https://github.com/sparkfish/modelc",
  "RemoteRef": "HEAD",
  "RemoteSha": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
  "NeedsCompilation": "no",
  "Packaged": {
    "Date": "2026-10-16 07:25:48 UTC",
    "User": "root"
  },
  "Author": "Hugo Saavedra [aut, cre]",
  "Maintainer": "Hugo Saavedra <analytics+hugo@sparkfish.com>",
  "_user": "sparkfish",
  "_type": "src",
  "_file": "modelc_1.0.0.0.tar.gz",
  "_fileid": "https://r2.ropensci.org/e71f5c0f474d2ad2ed36e812fda458aff37a958e47431d4a14261fb63dfb1f70",
  "_filesize": 100305,
  "_sha256": "e71f5c0f474d2ad2ed36e812fda458aff37a958e47431d4a14261fb63dfb1f70",
  "_expires": "2027-01-24T07:44:38.000Z",
  "_created": "2026-10-16T07:25:48.000Z",
  "_published": "2026-10-16T07:44:40.204Z",
  "_buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069",
  "_status": "success",
  "_host": "GitHub-Actions",
  "_jobs": [
    {
      "job": 116862607608,
      "time": 89,
      "config": "linux-devel-x86_64",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "12031817206"
    },
    {
      "job": 116862607686,
      "time": 99,
      "config": "linux-release-x86_64",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "12032160289"
    },
    {
      "job": 116862607581,
      "time": 149,
      "config": "macos-oldrel-arm64",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "12031904513"
    },
    {
      "job": 116862607668,
      "time": 150,
      "config": "macos-release-arm64",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "12032258268"
    },
    {
      "job": 116861801179,
      "time": 142,
      "config": "source",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "12031726430"
    },
    {
      "job": 116862607564,
      "time": 68,
      "config": "wasm-release",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "12032200116"
    },
    {
      "job": 116862607592,
      "time": 58,
      "config": "windows-devel-x86_64",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "12031861973"
    },
    {
      "job": 116862607590,
      "time": 61,
      "config": "windows-oldrel-x86_64",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "12031676956"
    },
    {
      "job": 116862607678,
      "time": 66,
      "config": "windows-release-x86_64",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "12031707569"
    }
  ],
  "_upstream": "https://github.com/sparkfish/modelc",
  "_commit": {
    "id": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
    "author": "Hugo Saavedra <hsaavedra@sparkfish.com>",
    "committer": "Hugo Saavedra <hsaavedra@sparkfish.com>",
    "message": "Fix DESCRIPTION file formatting issues, update GitHub links\n",
    "time": 1592507174
  },
  "_maintainer": {
    "name": "Hugo Saavedra",
    "email": "analytics+hugo@sparkfish.com"
  },
  "_distro": "resolute",
  "_registered": true,
  "_dependencies": [
    {
      "package": "testthat",
      "version": ">= 2.1.0",
      "role": "Suggests"
    }
  ],
  "_owner": "sparkfish",
  "_selfowned": true,
  "_usedby": 0,
  "_updates": [],
  "_tags": [],
  "_topics": [
    "compiler",
    "generalized-linear-models",
    "linear-models",
    "sql",
    "transpiler"
  ],
  "_stars": 1,
  "_contributors": [
    {
      "user": "polynomialherder",
      "count": 18,
      "uuid": 18321626
    },
    {
      "user": "jboarman",
      "count": 5,
      "uuid": 1108065
    }
  ],
  "_userbio": {
    "uuid": 24844869,
    "type": "organization",
    "name": "Sparkfish",
    "followers": 25
  },
  "_downloads": {
    "count": 205,
    "source": "https://cranlogs.r-pkg.org/downloads/total/last-month/modelc"
  },
  "_devurl": "https://github.com/sparkfish/modelc",
  "_searchresults": 1,
  "_rbuild": "4.6.1",
  "_assets": [
    "extra/citation.cff",
    "extra/citation.html",
    "extra/citation.json",
    "extra/citation.txt",
    "extra/contents.json",
    "extra/manual.pdf",
    "extra/modelc.html",
    "extra/readme.html",
    "extra/readme.md",
    "LICENSE"
  ],
  "_homeurl": "https://github.com/sparkfish/modelc",
  "_realowner": "sparkfish",
  "_cranurl": true,
  "_releases": [
    {
      "version": "1.0.0.0",
      "date": "2020-06-28"
    }
  ],
  "_exports": [
    "modelc"
  ],
  "_help": [
    {
      "page": "apply_linkinverse",
      "title": "Wrap the model SQL in the appropriate link function inverse to return scaled predictions",
      "topics": [
        "apply_linkinverse"
      ]
    },
    {
      "page": "build_additive_term",
      "title": "Get SQL representing a continuous term in the model with no interactions",
      "topics": [
        "build_additive_term"
      ]
    },
    {
      "page": "build_factor_case_statements",
      "title": "Build SQL CASE statements representing the factors in the model",
      "topics": [
        "build_factor_case_statements"
      ]
    },
    {
      "page": "build_interaction_term",
      "title": "Build a SQL interaction term",
      "topics": [
        "build_interaction_term"
      ]
    },
    {
      "page": "build_intercept",
      "title": "Get SQL representing the intercept term given the R model and parameter name",
      "topics": [
        "build_intercept"
      ]
    },
    {
      "page": "build_product",
      "title": "Build a SQL product",
      "topics": [
        "build_product"
      ]
    },
    {
      "page": "extract_level",
      "title": "Extract the level from the factor name",
      "topics": [
        "extract_level"
      ]
    },
    {
      "page": "extract_parameter_coefficient",
      "title": "Extract the coefficient of a model parameter",
      "topics": [
        "extract_parameter_coefficient"
      ]
    },
    {
      "page": "extract_parameters",
      "title": "Extract parameters from a linear model",
      "topics": [
        "extract_parameters"
      ]
    },
    {
      "page": "get_factor_name",
      "title": "Extract the factor name from an R model",
      "topics": [
        "get_factor_name"
      ]
    },
    {
      "page": "has_parameter",
      "title": "Check if an R model contains a coefficient",
      "topics": [
        "has_parameter"
      ]
    },
    {
      "page": "is_factor",
      "title": "Detect if the given model term is a factor",
      "topics": [
        "is_factor"
      ]
    },
    {
      "page": "is_interaction",
      "title": "Detect if the given model term is an interaction",
      "topics": [
        "is_interaction"
      ]
    },
    {
      "page": "is_intercept",
      "title": "Check if the given parameter is the intercept",
      "topics": [
        "is_intercept"
      ]
    },
    {
      "page": "modelc",
      "title": "Compile an R model to a valid TSQL formula",
      "topics": [
        "modelc"
      ]
    }
  ],
  "_readme": "https://github.com/sparkfish/modelc/raw/HEAD/README.md",
  "_rundeps": [],
  "_score": 2.6989700043360187,
  "_indexed": true,
  "_nocasepkg": "modelc",
  "_universes": [
    "sparkfish"
  ],
  "_binaries": [
    {
      "r": "4.7.0",
      "os": "linux",
      "version": "1.0.0.0",
      "date": "2026-10-16T07:27:25.000Z",
      "distro": "resolute",
      "commit": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
      "fileid": "https://r2.ropensci.org/c605e8a06f441d129ac6813280beaf7d65de1ae4e5c6f4af3e61d3941ece3661",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069"
    },
    {
      "r": "4.6.1",
      "os": "linux",
      "version": "1.0.0.0",
      "date": "2026-10-16T07:27:34.000Z",
      "distro": "resolute",
      "commit": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
      "fileid": "https://r2.ropensci.org/083afed278953e23cd13fd3f4e1082047e8d3a9002b41a174983bc0002123ef8",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069"
    },
    {
      "r": "4.5.3",
      "os": "mac",
      "version": "1.0.0.0",
      "date": "2026-10-16T07:41:58.000Z",
      "commit": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
      "fileid": "https://r2.ropensci.org/288c5f15194b35c51ddc163788cc7f17b031dabf37333daa0783ab96f993cbec",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069"
    },
    {
      "r": "4.6.1",
      "os": "mac",
      "version": "1.0.0.0",
      "date": "2026-10-16T07:43:24.000Z",
      "commit": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
      "fileid": "https://r2.ropensci.org/72e57b2b7956970065cc767f0891688cf4276548edaeee9fd11623430a0eb903",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069"
    },
    {
      "r": "4.6.0",
      "os": "wasm",
      "version": "1.0.0.0",
      "date": "2026-10-16T07:27:13.000Z",
      "commit": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
      "fileid": "https://r2.ropensci.org/05a036267030f0b2fcc32de356eb3d415bccedae63d30b30bb771544b96511e0",
      "status": "success",
      "buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069"
    },
    {
      "r": "4.7.0",
      "os": "win",
      "version": "1.0.0.0",
      "date": "2026-10-16T07:26:49.000Z",
      "commit": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
      "fileid": "https://r2.ropensci.org/a274cf4c64cf187f089210bc12d1c6fbb0fde1ce88038ef909921f895fe55a67",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069"
    },
    {
      "r": "4.5.3",
      "os": "win",
      "version": "1.0.0.0",
      "date": "2026-10-16T07:26:51.000Z",
      "commit": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
      "fileid": "https://r2.ropensci.org/3236141c0492c28a86c18d368648212cfa4cfb62c37aeb7fe9f6ef80de598303",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069"
    },
    {
      "r": "4.6.1",
      "os": "win",
      "version": "1.0.0.0",
      "date": "2026-10-16T07:26:58.000Z",
      "commit": "2f6a779e2349ac49898fff749dffbf0ad12d40cb",
      "fileid": "https://r2.ropensci.org/5c0ad9917d3e9c1beae4aee536989521706f7dd1d71318a4581b2f3d94a32b10",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/sparkfish/actions/runs/38866900069"
    }
  ]
}