Skip to content

Commit

Permalink
Fix minor formatting issues in README
Browse files Browse the repository at this point in the history
  • Loading branch information
ngmarchant committed Dec 2, 2020
1 parent d04d140 commit 69476ba
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 10 deletions.
6 changes: 4 additions & 2 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,13 @@ knitr::opts_chunk$set(
clevr implements functions for evaluating link prediction and clustering
algorithms in R. It includes efficient implementations of common performance
measures, such as:

* pairwise precision, recall, F-measure;
* homogeneity, completeness and V-measure;
* (adjusted) Rand index;
* variation of information; and
* mutual information.

While the current focus is on supervised (a.k.a. external) performance
measures, unsupervised (internal) measures are also in scope for future
releases.
Expand Down Expand Up @@ -54,7 +56,7 @@ representations.
```{r example}
library(clevr)
# A clustering of four records represented as a membership vector
pred_membership <- c("Record1" = 1, "Record2" = 1, "Record3" = 1, "Record 4" = 2)
pred_membership <- c("Record1" = 1, "Record2" = 1, "Record3" = 1, "Record4" = 2)
# Represent as a set of record pairs that appear in the same cluster
pred_pairs <- membership_to_pairs(pred_membership)
Expand All @@ -80,7 +82,7 @@ print(re)
and for evaluating clusterings:

```{r clust-measures}
true_membership <- c("Record1" = 1, "Record2" = 1, "Record3" = 2, "Record 4" = 2)
true_membership <- c("Record1" = 1, "Record2" = 1, "Record3" = 2, "Record4" = 2)
ari <- adj_rand_index(true_membership, pred_membership)
print(ari)
Expand Down
22 changes: 14 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,17 @@

clevr implements functions for evaluating link prediction and clustering
algorithms in R. It includes efficient implementations of common
performance measures, such as: \* pairwise precision, recall, F-measure;
\* homogeneity, completeness and V-measure; \* (adjusted) Rand index; \*
variation of information; and \* mutual information. While the current
focus is on supervised (a.k.a. external) performance measures,
unsupervised (internal) measures are also in scope for future releases.
performance measures, such as:

- pairwise precision, recall, F-measure;
- homogeneity, completeness and V-measure;
- (adjusted) Rand index;
- variation of information; and
- mutual information.

While the current focus is on supervised (a.k.a. external) performance
measures, unsupervised (internal) measures are also in scope for future
releases.

## Installation

Expand All @@ -39,7 +45,7 @@ clustering representations.
``` r
library(clevr)
# A clustering of four records represented as a membership vector
pred_membership <- c("Record1" = 1, "Record2" = 1, "Record3" = 1, "Record 4" = 2)
pred_membership <- c("Record1" = 1, "Record2" = 1, "Record3" = 1, "Record4" = 2)

# Represent as a set of record pairs that appear in the same cluster
pred_pairs <- membership_to_pairs(pred_membership)
Expand All @@ -56,7 +62,7 @@ print(pred_clusters)
#> [1] "Record1" "Record2" "Record3"
#>
#> $`2`
#> [1] "Record 4"
#> [1] "Record4"
```

Performance measures are available for evaluating linked pairs:
Expand All @@ -76,7 +82,7 @@ print(re)
and for evaluating clusterings:

``` r
true_membership <- c("Record1" = 1, "Record2" = 1, "Record3" = 2, "Record 4" = 2)
true_membership <- c("Record1" = 1, "Record2" = 1, "Record3" = 2, "Record4" = 2)

ari <- adj_rand_index(true_membership, pred_membership)
print(ari)
Expand Down

0 comments on commit 69476ba

Please sign in to comment.