Skip to content

Commit 930fe47

Browse files
mk314199cran-robot
authored andcommitted
version 2.7-12
1 parent 68d8bab commit 930fe47

30 files changed

+110
-860
lines changed

DESCRIPTION

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: pcalg
2-
Version: 2.7-11
3-
Date: 2024-02-12
2+
Version: 2.7-12
3+
Date: 2024-09-12
44
Title: Methods for Graphical Models and Causal Inference
55
Description: Functions for causal structure
66
learning and causal inference using graphical models. The main algorithms
@@ -34,7 +34,7 @@ NeedsCompilation: yes
3434
Encoding: UTF-8
3535
License: GPL (>= 2)
3636
URL: https://pcalg.r-forge.r-project.org/
37-
Packaged: 2024-02-12 10:30:09 UTC; kalischm
37+
Packaged: 2024-09-12 08:25:27 UTC; kalischm
3838
Author: Markus Kalisch [aut, cre],
3939
Alain Hauser [aut],
4040
Martin Maechler [aut],
@@ -53,4 +53,4 @@ Author: Markus Kalisch [aut, cre],
5353
Leonard Henckel [ctb],
5454
Joris Mooij [ctb]
5555
Repository: CRAN
56-
Date/Publication: 2024-02-12 12:00:05 UTC
56+
Date/Publication: 2024-09-12 17:40:27 UTC

MD5

+28-28
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
1c213fc1c5a5ec68e7a5ba9293440dc3 *ChangeLog
2-
440a9d31b6239ad5dcca646c3094c714 *DESCRIPTION
2+
df21900a61d14d6ed06eb49da18d0da3 *DESCRIPTION
33
79fd4acb4bfb63ec9e5f128b83d9b519 *NAMESPACE
44
1ff3899574f2834d3ccd16abecf9bb1a *R/Aaux.R
55
b93a5be8eca41fda6c169327121fbf98 *R/AllClasses.R
@@ -27,8 +27,8 @@ be8549091476fb77e357c1eb091126dd *R/searchAM.R
2727
87a281b79088f0d9ab6974755915e0d4 *R/udag2pag.R
2828
0db1ba6d57801a4d8fc6cdf996384a4d *R/zzz.R
2929
d599e23940bca0203504c0fa6b09e01c *TODO
30-
7080893e02c49cd296d4424b9be55069 *build/partial.rdb
31-
d758c7bd1bc4de0d72601af7f33f28d7 *build/vignette.rds
30+
e23903adc990d9515ba1ebd23e3bff59 *build/partial.rdb
31+
7294bcfa49420edc123dbca6ade01655 *build/vignette.rds
3232
f832779eae511757a99906c7670fc0ad *cleanup
3333
7cbe431a233e6c454e24f7b92d63fe75 *data/datalist
3434
1d8d4c43b9cbb9dc9dd57acd59f565bf *data/gmB.rda
@@ -42,7 +42,7 @@ f0d1c0728b0d9fcf297e6f0c48893ebd *inst/NEWS.Rd
4242
4e33425acbef8bf36705d8a75622baa8 *inst/doc/mkVignettes.R
4343
415ef587902bfe185df240f1fd7a983f *inst/doc/vignette2018.R
4444
e3ccf4421514bf7e337aa67d75bde656 *inst/doc/vignette2018.Rnw
45-
2969d85808d0f6373b26d73301641825 *inst/doc/vignette2018.pdf
45+
1d30b28e985c54ef030ab82ee66239e3 *inst/doc/vignette2018.pdf
4646
cee0b4475c720bf58c466e1495451b22 *inst/external/N_6_1000.rds
4747
0d84fdc119d76d992b72f9bdbd0e613d *inst/external/gac-pags.rds
4848
e7a2a9117d97986b2ab6afc6b4f77478 *inst/external/test_conservative_pc_data1.rda
@@ -57,23 +57,23 @@ aa3405ae18b89d66c1a0315e0bdbccee *inst/xtraR/graph2ftmatrix.R
5757
146b7ce241783ddaa4627949ae1f370a *man/GaussL0penIntScore-class.Rd
5858
7a13c14340cd1794323ce09720787218 *man/GaussL0penObsScore-class.Rd
5959
84f4260988cdcfafadee14e0bbe56cc9 *man/GaussParDAG-class.Rd
60-
4c1a2c4b81350916099f7952358f9550 *man/LINGAM.Rd
60+
f66e9e4dfe482c8eaa28f06812ffa66f *man/LINGAM.Rd
6161
4733da421bc6790c136557833a08b0dc *man/ParDAG-class.Rd
6262
84fcdb8aca0888d4a312f23d1c9ca46c *man/Score-class.Rd
6363
377940596c67e1dd0c304d17f0dd8c89 *man/addBgKnowledge.Rd
6464
10598435a2f4beaab82a426fd62e4c55 *man/adjustment.Rd
65-
dab3cfa8aee7b15acfce954f4d63a030 *man/ages.Rd
66-
8a41e2a67114f073aef8388fdf316531 *man/amatType.Rd
65+
240c028d0bf23ae2f17e1071c9e26f9c *man/ages.Rd
66+
df2763427d81575578463e6a2a19c343 *man/amatType.Rd
6767
ae81d09d32bc121b2b84c1a2138dd9fb *man/backdoor.Rd
6868
6feb25e396846cbb7c1fc4de8d7e2eaa *man/beta.special.Rd
6969
e5e54569fa1222405f18ee7c189b68cd *man/beta.special.pcObj.Rd
7070
25029c568795bdac3d6f3b8e9e05326a *man/binCItest.Rd
7171
966d0b8af075b8f40c5f1021abb41f67 *man/checkTriple.Rd
7272
4b0dfb506510f7cf16ebc7e3e6fb6339 *man/compareGraphs.Rd
7373
297092d27f80a859b5d89a49a54926d1 *man/condIndFisherZ.Rd
74-
b2ded6b2c0cd2cf0c30b845d07646736 *man/corGraph.Rd
74+
48a29470740bc47e434343007e798ce3 *man/corGraph.Rd
7575
14cc497daabf3441d1c1db24ef338244 *man/dag2cpdag.Rd
76-
4cb38ff25dcd9cdf5c983da476409c8b *man/dag2essgraph.Rd
76+
ad4fcb4e1f73ffd1483862b88eb950d2 *man/dag2essgraph.Rd
7777
9825306a115fb2370a8bf8d481284983 *man/dag2pag.Rd
7878
4e804b480585e6a4d57b1ac0f6100760 *man/disCItest.Rd
7979
3d880e7f58fe68731e9ed4ecb4c13bf4 *man/dreach.Rd
@@ -83,19 +83,19 @@ aec0e014304481b623884999c309d810 *man/dsepAMTest.Rd
8383
bca518ac995023186ff2945b62486043 *man/dsepTest.Rd
8484
18e3f7854dd0af498e231296825f64cc *man/fci.Rd
8585
4210c617d4929290e295ced5e0eeeb43 *man/fciAlgo-class.Rd
86-
adce79a344a395951d251d5fbb63b1d9 *man/fciPlus.Rd
86+
94407964a7b930180e35672a2ac86aa2 *man/fciPlus.Rd
8787
44127d2a6a6234ed84cf650a3273e504 *man/find.unsh.triple.Rd
8888
efed404b8bbbd6700520e6587d65d4ac *man/gAlgo-class.Rd
8989
b7b554b6006cf4a67024618db013e5ed *man/gac.Rd
9090
cb526c1eceaf53b0239c888ecbbdbbaf *man/gds.Rd
91-
318fbf7901347ed604e65d13ccfe9e88 *man/ges.Rd
92-
fdc0ad5d17fff5f2c8734504041af969 *man/getGraph.Rd
91+
932c079ecf9b2d271ee279647376deae *man/ges.Rd
92+
54662d98d24003eef72b1193565d4dd6 *man/getGraph.Rd
9393
f7e5c22255b62a23431b08c2d3080b66 *man/getNextSet.Rd
9494
6d8175892f5ba9aa3ac75187bbfa5c89 *man/gies.Rd
9595
cbb33c4976caf365b69cb9c76a7a493e *man/gmB.Rd
9696
5d6bd5e0a6ddce6b8b4dae1dc02bd26c *man/gmD.Rd
97-
44fc91f89bacfcf44cc596240aa5895f *man/gmG.Rd
98-
66a7855809f1fd6e9a0ced7dbd612af6 *man/gmI.Rd
97+
6e0e58a3ea2ba21d0e3df60b6f8d77c0 *man/gmG.Rd
98+
7299a9b977703f1155b39fc5eacef145 *man/gmI.Rd
9999
6a624691a6a19dd55526a9e9585ce0b3 *man/gmInt.Rd
100100
0fc0725cd27113dfa0505deb9504b3ec *man/gmL.Rd
101101
09869c2316e23e93cb53a2863f74cbfb *man/ida.Rd
@@ -106,33 +106,33 @@ bc93b0a2d31d65d8e33fac866edcc3ff *man/jointIda.Rd
106106
240d9c697a86a1aad34a623a487d3f5e *man/legal.path.Rd
107107
7c28e6a542763fa65c25784a96d32e1f *man/mat2targets.Rd
108108
cd8a6e38249822fc7c54c66b96a6a967 *man/mcor.Rd
109-
1c7ed5406ee7aed47987da8900ab144e *man/opt.target.Rd
110-
088eee045f4ee07c7fd39971203f4c18 *man/optAdjSet.Rd
109+
03b85555134c828b6d3eb61d30f08754 *man/opt.target.Rd
110+
93b991d491eb1246af2ccc3483c4efa6 *man/optAdjSet.Rd
111111
b19638bed84ac520eef81968bf75eec7 *man/pag2anc.Rd
112112
4d3e89b74016644821e676808d9ac720 *man/pag2conf.Rd
113113
a05d67efd1b2ecef92b144176a7e4802 *man/pag2edge.Rd
114114
67426f4203b1334a56a8715423083745 *man/pag2mag.Rd
115115
999058226d5b92a97826254353da24b9 *man/pc.Rd
116116
01d980deb40fe93c7e3c2f5039882f9d *man/pc.cons.intern.Rd
117-
342566226ce52d9795a928ef44a7ca3c *man/pcAlgo-class.Rd
117+
b85ec6d5f9f8caf5aa6a458e1a155eeb *man/pcAlgo-class.Rd
118118
143110b2d6797b5ef727a5c05d2790f8 *man/pcAlgo.Rd
119119
9ac47786c259e034f8884a317471413c *man/pcSelect.Rd
120120
ef7c030654d7a92a9664076d2a0eac5f *man/pcSelect.presel.Rd
121121
7b6d586d1487a8147af049ddff205984 *man/pcalg-internal.Rd
122122
85c443f6cceb717c08a7405a693759ba *man/pcalg2dagitty.Rd
123123
69e62cafe0cebc0d0d4faac5ad06408e *man/pcorOrder.Rd
124-
800c3348670b4ca01c406d5e5d67839c *man/pdag2allDags.Rd
124+
4d4299e5a352bec011257e53bfd3634f *man/pdag2allDags.Rd
125125
208807c0c6b5ead3e89f414adc9136c1 *man/pdag2dag.Rd
126126
23be39839c6b197c4e4d4b795434c897 *man/pdsep.Rd
127127
89b20dd90d54188d453dde9d8ca13d07 *man/plotAG.Rd
128128
a68ad0b469bf17525891e7670bfee92a *man/plotSG.Rd
129-
a0959170421383962a6da152d50a7533 *man/possAn.Rd
130-
f25aca5cbb7a581b13d96fb52b520ff7 *man/possDe.Rd
129+
54df65eb3082bb6c3d71d25a5015aced *man/possAn.Rd
130+
c79ecb227810b093283ddc9008e3d0ce *man/possDe.Rd
131131
7f5b7ce6779ae9d3536ed8d2f4c61ddc *man/possibleDe.Rd
132132
5782fc04b6408ebfc706d4d43d232fb1 *man/qreach.Rd
133133
d0196c418afe2af7c6bf89cd2a5d18e5 *man/r.gauss.pardag.Rd
134-
a2b64baab3e522ab16fb7eabcf6d4b0e *man/randDAG.Rd
135-
d28b8fbb54c9bdd378363a74325fcb8a *man/randomDAG.Rd
134+
cd0bb4991af0eb3495d50b38d7a5c824 *man/randDAG.Rd
135+
1c99d0898bf5b63f24c4049edeb17f70 *man/randomDAG.Rd
136136
7d17d98b4d76d4ae6ee5646d94b7d18d *man/rfci.Rd
137137
d6eb86a8b2f04f416a59792f35cdaa2c *man/rmvDAG.Rd
138138
27ab6d09110842495dd1b29fc14f1543 *man/rmvnorm.ivent.Rd
@@ -155,11 +155,12 @@ abddab27448a30a0f87aea03c467e0ee *man/visibleEdge.Rd
155155
35da0b2746092325096fa471446e465e *src/greedy.cpp
156156
c5e0eb959f4162f8655ea795eec34c50 *src/init.c
157157
bc5cab68e323949bed42d3d87b68e5a2 *src/score.cpp
158-
2a3703c998cfee5643aba359c366c621 *tests/Rplots.pdf
158+
7e9becd2ef6f689c10618dd96b69a7c8 *tests/Rplots.pdf
159159
83187ba1f22cdb1b239e07027ddf489a *tests/discr100k.rda
160+
4d3ceefb0a5c86642b5ccc887758358e *tests/filesToFix_Tests.txt
160161
d41d8cd98f00b204e9800998ecf8427e *tests/nohup.out
161162
e55f723241bfbf463ec914b2bcc694d0 *tests/test_LINGAM.R
162-
daeeb27e6aae053f7b69fa562716582f *tests/test_addBgKnowledge.R
163+
2d43ff479d17e1f0371108624fa71f9a *tests/test_addBgKnowledge.R
163164
94d9a6136b5d720bfa53e96616e459ca *tests/test_adjustment.R
164165
d90e667e134646f47bb8e06972d7601d *tests/test_ages.R
165166
3e75e91dc9507a780c188cd62c65636b *tests/test_amat2dag.R
@@ -200,11 +201,10 @@ aac037b24388c480eb395a2ae9fafc69 *tests/test_pcalg2dagitty.R
200201
ecaacf0c68bf72d9d96eeeeffd824357 *tests/test_pcorOrder.R
201202
67fbdda0dd8ab5f4fbd185ee85916d12 *tests/test_pdag2allDags.R
202203
76fd1ade1f75af8bbdcc8d88b655fbdc *tests/test_pdag2dag.R
203-
6e781edbdbfa26fbff95bac51ebac9bc *tests/test_possDeAn.R
204-
507c58ed9fd5d94df32413b3293b4618 *tests/test_randDAG.R
205-
df10c14587ea074ed0f3b95f3211f81a *tests/test_randDAG.Rout.save
204+
5f665e5d0891a92bdbac7fcffb7860d1 *tests/test_possDeAn.R
205+
dbdcee5fd6b2be716c6bdff785441167 *tests/test_randDAG.R
206206
aee8ad2108a151b25666eaf0ed1b4205 *tests/test_randomDAG.R
207-
e265f1b5aa31a977b1d25841ceebf3dd *tests/test_rfci.R
207+
37b491b0af1332bd0713579bd0a16da7 *tests/test_rfci.R
208208
aca0d1fb3b38a6f54fb2d84040aa009d *tests/test_rmvDAG.R
209209
d795c92a5d7f9fa10296170c950bd5f1 *tests/test_searchAM.R
210210
c1564ccaf570fb24d5e19ffd8d8e4d04 *tests/test_shd.R

build/partial.rdb

4 Bytes
Binary file not shown.

build/vignette.rds

0 Bytes
Binary file not shown.

inst/doc/vignette2018.pdf

-1.61 KB
Binary file not shown.

man/LINGAM.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ LINGAM(X, verbose = FALSE)
5757
and Jonas Peters <[email protected]>.
5858
}
5959
\seealso{
60-
\code{\link{fastICA}} from package \pkg{fastICA} is used.
60+
\code{\link[fastICA]{fastICA}} from package \pkg{fastICA} is used.
6161
}
6262
\examples{
6363
##################################################

man/ages.Rd

+6-2
Original file line numberDiff line numberDiff line change
@@ -144,11 +144,12 @@ score <- new("GaussL0penObsScore", data)
144144
ges.fit <- ges(score, phase = c("forward","backward"), iterate = FALSE)
145145

146146
## Plots
147+
if (require(Rgraphviz)) {
147148
par(mfrow=c(1,3))
148149
plot(ges.fit$essgraph, main="Estimated CPDAG with GES")
149150
plot(ages.fit$essgraph, main="Estimated APDAG with AGES")
150151
plot(gGtrue, main="TrueDAG")
151-
152+
}
152153

153154

154155
## Example 2: ages adds correct orientations: Author --> Goal and Author --> V5
@@ -175,11 +176,12 @@ score <- new("GaussL0penObsScore", data)
175176
ges.fit <- ges(score, phase = c("forward","backward"), iterate = FALSE)
176177

177178
## Plots
179+
if (require(Rgraphviz)) {
178180
par(mfrow=c(1,3))
179181
plot(ges.fit$essgraph, main="Estimated CPDAG with GES")
180182
plot(ages.fit$essgraph, main="Estimated APDAG with AGES")
181183
plot(gGtrue, main="TrueDAG")
182-
184+
}
183185

184186
## Example 3: ges and ages return the same graph
185187

@@ -197,11 +199,13 @@ ges.fit <- ges(score)
197199

198200

199201
## Plots
202+
if (require(Rgraphviz)) {
200203
par(mfrow=c(1,3))
201204
plot(ges.fit$essgraph, main="Estimated CPDAG with GES")
202205
plot(ages.fit$essgraph, main="Estimated APDAG with AGES")
203206
plot(gmG8$g, main="TrueDAG")
204207
}
208+
}
205209
% Add one or more standard keywords, see file 'KEYWORDS' in the
206210
% R documentation directory.
207211
\keyword{models}% use one of RShowDoc("KEYWORDS")

man/amatType.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
adjacency matrix as input; \code{\linkS4class{fciAlgo}} for a class
7575
which has an adjacency matrix in one slot.
7676

77-
\code{\link{getGraph}(x)} extracts the \code{\linkS4class{graph}}
77+
\code{\link{getGraph}(x)} extracts the \code{\link[graph]{graph-class}}
7878
object from \code{x}, whereas \code{as(*, "amat")} gets the
7979
corresponding adjacency matrix.
8080
}

man/corGraph.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ corGraph(dm, alpha=0.05, Cmethod="pearson")
1919
abbreviated.}
2020
}
2121
\value{
22-
Undirected correlation graph, a \code{\linkS4class{graph}} object
22+
Undirected correlation graph, a \code{\link[graph]{graph-class}} object
2323
(package \pkg{graph}); \code{\link{getGraph}} for the \dQuote{fitted}
2424
graph.
2525
}

man/dag2essgraph.Rd

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ dag2essgraph(dag, targets = list(integer(0)))
1414
\arguments{
1515
\item{dag}{The DAG whose essential graph has to be calculated. Different
1616
representations are possible: \code{dag} can be an
17-
object of \code{\linkS4class{graphNEL}} (package \pkg{graph}) or
17+
object of \code{\link[graph]{graphNEL}} (package \pkg{graph}) or
1818
an instance of a class derived from \code{\linkS4class{ParDAG}}.}
1919

2020
\item{targets}{List of intervention targets with respect to which the
@@ -43,7 +43,7 @@ dag2essgraph(dag, targets = list(integer(0)))
4343
\value{
4444
Depending on the class of \code{dag}, the essential graph is returned as
4545
\itemize{
46-
\item{an instance of \code{\linkS4class{graphNEL}}, if \code{dag} is an
46+
\item{an instance of \code{\link[graph]{graphNEL}}, if \code{dag} is an
4747
instance of \code{graphNEL},}
4848
\item{an instance of \code{\linkS4class{EssGraph}}, if \code{dag} is
4949
an instance of a class derived from \code{\linkS4class{ParDAG}}.}

man/fciPlus.Rd

+3-2
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,11 @@ m.fci <- fciPlus(suffStat, indepTest=gaussCItest,
9494
alpha = 0.9999, p=p)
9595
summary(m.fci)
9696

97-
## require("Rgraphviz")
98-
sfsmisc::mult.fig(2, main="True DAG // fciPlus(.) \"oracle\" estimate")
97+
if (require(Rgraphviz)) {
98+
par(mfrow=c(1,2))
9999
plot(myDAG)
100100
plot(m.fci)
101+
}
101102

102103
##################################################
103104
## Joint Causal Inference Example

man/ges.Rd

+3-1
Original file line numberDiff line numberDiff line change
@@ -186,8 +186,10 @@ if (require(Rgraphviz)) {
186186
par(mfrow=c(1,2))
187187
plot(ges.fit$essgraph, main = "Estimated CPDAG")
188188
plot(gmG8$g, main = "True DAG")
189-
} else { ## alternative:
190189
str(ges.fit, max=2)
190+
}
191+
## alternative:
192+
if (require(Matrix)) {
191193
as(as(ges.fit$essgraph,"graphNEL"),"Matrix")
192194
}
193195
}

man/getGraph.Rd

+4-4
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
\alias{getGraph,pcAlgo-method}
88
\title{Get the "graph" Part or Aspect of R Object}
99
\description{
10-
Get the \code{\linkS4class{graph}} part or \dQuote{aspect} of an \R
10+
Get the \code{\link[graph]{graph-class}} part or \dQuote{aspect} of an \R
1111
object, notably from our \code{\link{pc}()}, \code{\link{skeleton}()},
1212
\code{\link{fci}()}, etc, results.
1313
}
@@ -19,7 +19,7 @@ getGraph(x)
1919
(with nodes and edges).}
2020
}
2121
\value{
22-
a \code{\linkS4class{graph}} object, i.e., one inheriting from (the
22+
a \code{\link[graph]{graph-class}} object, i.e., one inheriting from (the
2323
virtual) class \code{"graph"}, package \pkg{graph}.
2424
}
2525
\section{Methods}{
@@ -31,7 +31,7 @@ getGraph(x)
3131
\item{\code{signature(x = "fciAlgo")}}{extract the graph part
3232
explicitly.}
3333
\item{\code{signature(x = "matrix")}}{interpret \code{x} as adjacency
34-
matrix and return the corresponding \code{"\linkS4class{graphAM}"}
34+
matrix and return the corresponding \code{"\link[graph]{graphAM}"}
3535
object.}
3636
}
3737
For sparseMatrix methods, see the \sQuote{Note}.
@@ -47,7 +47,7 @@ getGraph(x)
4747
\author{Martin Maechler}
4848
\seealso{
4949
\code{\link{fci}}, etc.
50-
The \code{\linkS4class{graph}} class description in package \pkg{graph}.
50+
The \code{\link[graph]{graph-class}} class description in package \pkg{graph}.
5151
}
5252
\examples{
5353
A <- rbind(c(0,1,0,0,1),

man/gmG.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ str(gmG, max=3)
4848
stopifnot(identical(gmG $ g, gmG8 $ g))
4949
if(dev.interactive()) { ## to save time in tests
5050
round(as(gmG $ g, "Matrix"), 2) # weight ("adjacency") matrix
51-
plot(gmG $ g)
51+
if (require(Rgraphviz)) plot(gmG$g)
5252
pairs(gmG$x, gap = 0,
5353
panel=function(...) smoothScatter(..., add=TRUE))
5454
}

man/gmI.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ str(gmI, max=3)
3737
stopifnot(identical(gmI $ g, gmI7 $ g))
3838
if(dev.interactive()) { ## to save time in tests
3939
round(as(gmI $ g, "Matrix"), 2) # weight ("adjacency") matrix
40-
plot(gmI $ g)
40+
if (require(Rgraphviz)) plot(gmI $ g)
4141
pairs(gmI$x, gap = 0,
4242
panel=function(...) smoothScatter(..., add=TRUE))
4343
}

man/opt.target.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
\usage{opt.target(essgraph, max.size, use.node.names = TRUE)}
1414
\arguments{
1515
\item{essgraph}{An \code{\linkS4class{EssGraph}} or
16-
\code{\linkS4class{graphNEL}} object representing a (observational or
16+
\code{\link[graph]{graphNEL}} object representing a (observational or
1717
interventional) essential graph (or "CPDAG").}
1818
\item{max.size}{Maximum size of the intervention target. Only 1 and the
1919
number of vertices of \code{essgraph} are allowed; the latter means no size

man/optAdjSet.Rd

+2
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,12 @@ myDAG <- randomDAG(p, prob = 0.3)
4949
myCPDAG <- dag2cpdag(myDAG)
5050
## true PDAG with added background knowledge 5 -> 6
5151
myPDAG <- addBgKnowledge(myCPDAG,5,6)
52+
if (require(Rgraphviz)) {
5253
par(mfrow = c(1,3))
5354
plot(myDAG)
5455
plot(myPDAG)
5556
plot(myCPDAG) ## plot of the graphs
57+
}
5658
5759
## if the CPDAG C is amenable relative to (X,Y),
5860
## the optimal set will be the same for all DAGs

man/pcAlgo-class.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949

5050
In addition, \code{"pcAlgo"} has slots
5151
\describe{
52-
\item{\code{graph}:}{Object of class \code{"\linkS4class{graph}"}:
52+
\item{\code{graph}:}{Object of class \code{"\link[graph]{graph-class}"}:
5353
the undirected or partially directed graph that was estimated.}
5454

5555
\item{\code{zMin}:}{Deprecated.}

man/pdag2allDags.Rd

+2
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ amat3 <- matrix(res3$dags[1,],5,5, byrow = TRUE)
6363
colnames(amat3) <- rownames(amat3) <- res3$nodeNms
6464
amat3
6565

66+
if (require(Rgraphviz)) {
6667
## for convenience a simple plotting function
6768
## for the function output
6869
plotAllDags <- function(res) {
@@ -83,3 +84,4 @@ amat2 ## adj.matrix corresponding to the first plot for expl 2
8384
plotAllDags(res3)
8485
amat3 ## adj.matrix corresponding to the first plot for expl 3
8586
}
87+
}

man/possAn.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ type = c("cpdag", "pdag", "dag", "mag", "pag"))
4949
## a -- b -> c
5050
amat <- matrix(c(0,1,0, 1,0,1, 0,0,0), 3,3)
5151
colnames(amat) <- rownames(amat) <- letters[1:3]
52-
plot(as(t(amat), "graphNEL"))
52+
if (require(Rgraphviz)) plot(as(t(amat), "graphNEL"))
5353

5454
possAn(m = amat, x = 3, possible = TRUE, ds = FALSE, type = "pdag") ## all nodes
5555
possAn(m = amat, x = 3, y = 2, possible = TRUE, ds = FALSE, type = "pdag") ## only node 1

0 commit comments

Comments
 (0)