Skip to content

Commit c073d9e

Browse files
committed
documenter
1 parent f84194d commit c073d9e

File tree

1 file changed

+13
-14
lines changed

1 file changed

+13
-14
lines changed

docs/src/index.md

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,20 @@ The routine calculates a set of weights that are closest in some sense to an ini
1212

1313
```julia
1414

15-
function doreweighting(
16-
data :: AbstractArray{ <:Real, 2 },
17-
initial_weights :: AbstractArray{ <:Real, 1 }, # a column
18-
target_populations :: AbstractArray{ <:Real, 1 }, # a row
15+
function do_reweighting(
16+
;
17+
data, # either AbstractMatrix or e.g dataframe
18+
initial_weights :: AbstractVector, # a column
19+
target_populations :: AbstractVector, # a row
1920
functiontype :: DistanceFunctionType,
20-
ru :: Real = 0.0,
21-
rl :: Real = 0.0,
22-
tolx :: Real = 0.000001,
23-
tolf :: Real = 0.000001 ) :: NamedTuple
21+
upper_multiple = 0.0,
22+
lower_multiple = 0.0,
23+
tol = 10^(-10),
24+
max_iterations = 100 )
2425

2526
```
26-
See the for a simple example, based on examples from the Creedy paper.
27+
28+
See the tests for simple examples, based on examples from the Creedy paper.
2729

2830
The form of 'closeness' used is determined by the `functiontype` parameter of
2931
enumerated type `DistanceFunctionType`. See the [Creedy and Deville and
@@ -34,6 +36,8 @@ Sarndal](#Bibliography) papers on these. Notes on these:
3436
* the other measures are taken from the Deville and Sarndal paper and pass simple tests but sometimes fail to converge in real-world situations; whether this is because of something inherent or some mistake I've made I'm unsure;
3537
* I believe Calmar implements different measures; see also D’Souza.
3638

39+
see: Merz (1994) for a good discussion on how to lay out the dataset.
40+
3741
## Functions and Data Structures
3842

3943
```@index
@@ -46,12 +50,7 @@ Modules = [SurveyDataWeighting]
4650

4751
## TODO
4852

49-
* I really need to use standard Julia optimiser packages, such as [Optim.jl](https://github.com/JuliaNLSolvers/Optim.jl);
5053
* Chase up and add different closeness measures, e.g the Entropy measure I remember from an old Atkinson and Gomulka working paper, and whatever I can find elsewhere;
51-
* the weird bug with the non-nested callback..
52-
* am I using abstract arrays correctly?
53-
* test with a huge dataset;
54-
* how can I integrate this with a DataFrame?
5554

5655
## Bibliography
5756

0 commit comments

Comments
 (0)