pagerank 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/README.md +2 -0
- data/lib/pagerank/pagerank.rb +2 -2
- data/lib/pagerank/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 888fa835ae41fd964f438c61101ca2382f06f36f
|
4
|
+
data.tar.gz: cfb5cf7bd08b7dc8b48ef8c432cbb31a809d9ebb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 257958280d30d85a219e949df81027fbade2eace8da0a30b5f276f417d30241041acf6a07b6fa0268301d1b86c70dfc728eeb6929af07d0a3729b61e42f78c42
|
7
|
+
data.tar.gz: 5fb0a5e121ce54aba48919336912d833d2f94e838959b691576c1a6a17766fdbd62d0548a1b2627206b5f8156a7e227359245b59d7cefe786715531999d990fa
|
data/.gitignore
CHANGED
data/README.md
CHANGED
@@ -1,5 +1,7 @@
|
|
1
1
|
# Pagerank
|
2
2
|
|
3
|
+
[![Build Status](https://travis-ci.org/himkt/pagerank.svg)](https://travis-ci.org/himkt/pagerank)
|
4
|
+
|
3
5
|
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/pagerank`. To experiment with that code, run `bin/console` for an interactive prompt.
|
4
6
|
|
5
7
|
TODO: Delete this and the text above, and describe your gem
|
data/lib/pagerank/pagerank.rb
CHANGED
@@ -48,11 +48,11 @@ module PageRank
|
|
48
48
|
if @back_links[from]
|
49
49
|
score = @score[from]
|
50
50
|
@back_links[from].each do |to|
|
51
|
-
score += @score[to]
|
51
|
+
score += 0.15 + 0.85 * @score[to]
|
52
52
|
end
|
53
53
|
@score[from] = score
|
54
54
|
else
|
55
|
-
@score[from] = 0
|
55
|
+
@score[from] = 0.15
|
56
56
|
end
|
57
57
|
end
|
58
58
|
|
data/lib/pagerank/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pagerank
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- himkt
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-06-
|
11
|
+
date: 2015-06-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|