texteffect
Discovering Latent Treatments in Text Corpora and Estimating Their Causal Effects
Description
Implements the approach described in Fong and Grimmer (2016) <https://aclweb.org/anthology/P/P16/P16-1151.pdf> for automatically discovering latent treatments from a corpus and estimating the average marginal component effect (AMCE) of each treatment. The data is divided into a training and test set. The supervised Indian Buffet Process (sibp) is used to discover latent treatments in the training set. The fitted model is then applied to the test set to infer the values of the latent treatments in the test set. Finally, Y is regressed on the latent treatments in the test set to estimate the causal effect of each treatment.
Downloads
176
Last 30 days
18644th
176
Last 90 days
176
Last year
CRAN Check Status
Show all 14 flavors
| Flavor | Status |
|---|---|
| r-devel-linux-x86_64-debian-clang | NOTE |
| r-devel-linux-x86_64-debian-gcc | NOTE |
| r-devel-linux-x86_64-fedora-clang | NOTE |
| r-devel-linux-x86_64-fedora-gcc | NOTE |
| r-devel-macos-arm64 | NOTE |
| r-devel-windows-x86_64 | NOTE |
| r-oldrel-macos-arm64 | NOTE |
| r-oldrel-macos-x86_64 | NOTE |
| r-oldrel-windows-x86_64 | NOTE |
| r-patched-linux-x86_64 | NOTE |
| r-release-linux-x86_64 | NOTE |
| r-release-macos-arm64 | NOTE |
| r-release-macos-x86_64 | NOTE |
| r-release-windows-x86_64 | NOTE |
Check details (16 non-OK)
CRAN incoming feasibility
Maintainer: ‘Christian Fong <christianfong@stanford.edu>’
No Authors@R field in DESCRIPTION.
Please add one, modifying
Authors@R: person(given = "Christian",
family = "Fong",
role = c("aut", "cre"),
email = "christianfong@stanford.edu")
as necessary.
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
CRAN incoming feasibility
Maintainer: ‘Christian Fong <christianfong@stanford.edu>’
No Authors@R field in DESCRIPTION.
Please add one, modifying
Authors@R: person(given = "Christian",
family = "Fong",
role = c("aut", "cre"),
email = "christianfong@stanford.edu")
as necessary.
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended to use link{sibp_param_search} instead of this function to search over multiple configurations of the most important parameters. So long as only the training data is used, the analyst can freely experimient with as many parameter configurations as he likes without corrupting his causal inferences. Once a parameter configuration is chosen, the user can then use \link{sibp_amce} on the test set to estimate the average marginal component effect (AMCE) for each treatment.}
| ^
checkRd: (-1) sibp.Rd:28: Lost braces; missing escapes or markup?
28 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variational approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp_amce.Rd:19: Lost braces
19 | \item{sibp.amce}{The table returned by code{sibp_amce}.}
| ^
Check History
NOTE 0 OK · 14 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE Mar 9, 2026
CRAN incoming feasibility
Maintainer: ‘Christian Fong <christianfong@stanford.edu>’
No Authors@R field in DESCRIPTION.
Please add one, modifying
Authors@R: person(given = "Christian",
family = "Fong",
role = c("aut", "cre"),
email = "christianfong@stanford.edu")
as necessary.
CRAN incoming feasibility
Maintainer: ‘Christian Fong <christianfong@stanford.edu>’
No Authors@R field in DESCRIPTION.
Please add one, modifying
Authors@R: person(given = "Christian",
family = "Fong",
role = c("aut", "cre"),
email = "christianfong@stanford.edu")
as necessary.
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended
Rd files
checkRd: (-1) infer_Z.Rd:16: Lost braces; missing escapes or markup?
16 | \item{nu}{Informally, the probability that the row document has the column treatment. Formally, the parameter for the variatioanl approximation of z_{i,k}, which is a Bernoulli distribution.}
| ^
checkRd: (-1) sibp.Rd:26: Lost braces
26 | It is recommended