Skip to content

Commit

Permalink
Update for Julia 1.9
Browse files Browse the repository at this point in the history
  • Loading branch information
cynddl committed Aug 6, 2022
1 parent 66f48dd commit 431fe41
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 188 deletions.
19 changes: 0 additions & 19 deletions .travis.yml

This file was deleted.

129 changes: 0 additions & 129 deletions Manifest.toml

This file was deleted.

8 changes: 7 additions & 1 deletion Project.toml
@@ -1,6 +1,6 @@
name = "Discreet"
uuid = "c2843242-4f35-58a6-a2a0-7e7527607317"
version = "0.3.1"
version = "0.3.2"

[deps]
Compat = "34da2185-b29b-5c13-b0c7-acf172513d20"
Expand All @@ -11,3 +11,9 @@ StatsBase = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91"
Compat = "2, 3.0, 3.1, 3.2"
StatsBase = "0.22, 0.23, 0.24, 0.25, 0.26, 0.27, 0.28, 0.29, 0.30, 0.31, 0.32, 0.33"
julia = "1"

[extras]
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[targets]
test = ["Test"]
5 changes: 2 additions & 3 deletions README.md
@@ -1,8 +1,7 @@
# Discreet

[![Build Status](https://travis-ci.org/cynddl/Discreet.jl.svg?branch=master)](https://travis-ci.org/cynddl/Discreet.jl)
[![Coverage Status](https://coveralls.io/repos/cynddl/Discreet.jl/badge.svg?branch=master&service=github)](https://coveralls.io/github/cynddl/Discreet.jl?branch=master)
[![codecov.io](http://codecov.io/github/cynddl/Discreet.jl/coverage.svg?branch=master)](http://codecov.io/github/cynddl/Discreet.jl?branch=master)
[![Build Status](https://github.com/cynddl/Discreet.jl/actions/workflows/CI.yml/badge.svg)](https://github.com/cynddl/Discreet.jl/actions/workflows/CI.yml)
[![Coverage status](http://codecov.io/github/cynddl/Discreet.jl/coverage.svg?branch=master)](http://codecov.io/github/cynddl/Discreet.jl?branch=master)

Discreet is a small opinionated toolbox to estimate entropy and mutual information from discrete samples. It contains methods to adjust results and correct over- or under-estimations.

Expand Down
4 changes: 1 addition & 3 deletions REQUIRE
@@ -1,3 +1 @@
julia 0.7
Compat
StatsBase
julia 1.0
31 changes: 0 additions & 31 deletions appveyor.yml

This file was deleted.

2 changes: 1 addition & 1 deletion src/entropy.jl
Expand Up @@ -68,7 +68,7 @@ end
function estimate_joint_entropy(x::AbstractVector, y::AbstractVector; method::Symbol=:Naive)
@assert length(x) == length(y) "Vectors must be the same length"

count = countmap([hash(yᵢ, hash(xᵢ)) for (xᵢ, yᵢ) zip(x, y)])
count = countmap([hash(yᵢ, hash(xᵢ)) for (xᵢ, yᵢ) zip(x, y)], alg=:dict)
freqs = FrequencyWeights(collect(values(count)))
entropy(freqs; method=method)
end
4 changes: 3 additions & 1 deletion test/runtests.jl
@@ -1,6 +1,8 @@
using Discreet
import StatsBase: FrequencyWeights, ProbabilityWeights
using Compat, Compat.Test

using Test
using Compat
import Compat.sum

freqs_uniform = FrequencyWeights([1, 1, 1, 1, 1, 1])
Expand Down

2 comments on commit 431fe41

@cynddl
Copy link
Owner Author

@cynddl cynddl commented on 431fe41 Aug 6, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/65781

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.3.2 -m "<description of version>" 431fe41314ca26a14f3c19e53c83f6fd7d546d74
git push origin v0.3.2

Please sign in to comment.