Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Plugins

Notices

Reply
 
Thread Tools Search this Thread
Old 12-14-2019, 11:41 AM   #1
Pr.BarnArt
Addict
Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.Pr.BarnArt ought to be getting tired of karma fortunes by now.
 
Pr.BarnArt's Avatar
 
Posts: 323
Karma: 400746
Join Date: Jun 2011
Device: Pocketbook 902 / Ipad air/ kindle paperwhite
[GUI Plugin] Float Rating (F_rating)

There were several who asked for a plugin which can get and store the decimal rating of goodreads.
I gave it a try, just because I like to tackle a problem. But I am not a very good programmer. So this is more or less for fun and there sure will be better/smarter ways to solve this.

For this you need two plugins:

1. Goodreads_rating
You can find it here or download it within calibre->preferences->plugins.

and
2. F_rating

At the main menu you see the option frating with an ugly icon and a menu.
The menu has two options
a. Set decimal rating.
This function will first check if the column exists, if not it will be created ( and you have to restart Calibre - see dialog-info when this happens).
If the column exists, the function will search for all the records with '#PrB.rating#' in the publisher field.
It will split those publisher-fields into publisher and rating,
The last item is placed in a custom column: gr_ratings
The separator '#PrB.rating#' will be deleted
In the publisher-field remains just the publisher's name.
Direct clicking the ugly icon, starts also this function.

b. Check and create custom column.
There will be info with the results of the check.
If the column is created you have to restart calibre.

Custom column
You can also create the custom column by the gui, use the next values.
Only the text of the label can be of your own choise.•name: gr1
•label: gr_ratings
•type: decimal or float

INSTALLATION (Thanks to arialvetica)

1. Download both linked plugins (current version is always at the bottom of the original post).
2. Install both linked plugins. To do this, click on "Preferences," then under the "Advanced" heading click on "Plugins." For each plugin, click on "Load plugin from file." Find the ZIP file you just downloaded, click "Open." Click "Yes" on the "Are you sure?" dialogue. Restart calibre after installing plugins.
3. There will be a new icon (looks like an orange starburst) in the main menu, called Frating. It has a menu with two options:
- Set decimal rating;
- Check and create custum column;

But you can also click the icon itself and it will run: set decimal rating;
This will check if there is already a custom column for this.
If not it wil create one and you have to restart calibre.
If the check is true, it will go on with putting the decimal rating in the custom column.

For creating the column you can also select the menu option: "Check and create custom column." (Optional: You can change the Column Heading through Preferences: Add Your Own Columns. Double-click on the #gr1 column, and type whatever you prefer in the "Column Heading" field. Do NOT change the lookup name.)


USAGE


To download ratings for an individual book (good for checking if you've done setup correctly.)
1. Click on a book title in the main calibre window.
2. Click on "Edit metadata individually".
3. Next to "Download metadata," click on the Configure Download icon (looks like a "Preferences/Settings" icon, hover-text should read "Change how calibre downloads metadata.")
4. Ensure "Goodreads_Rating" is the ONLY checked Source, then Apply changes.
5. Click on "Download metadata".
6. When the download is complete, click "OK" first for the metadata, then "OK" again for the cover.
7. Click "OK" again to save changes and close the Edit Metadata window.
8. Click on the "Run frating" icon (looks like an orange starburst).
After this processes, you'll see a dialogue box either confirming whether it worked ("Finished extracting rating from publisherfield - for a total of X books") or not ("Finished extracting rating from publisherfield - for a total of 0 books"). Click OK to close the dialogue. Now, in the main calibre window, in this book's row and under the gr_ratings column, you should see a number ranging from 0.0 to 5.0.

To download ratings in bulk
1. Select a range of books in the main calibre window.
2. Click on "Download metadata and covers".
3. Click on "Configure Download".
4. Ensure "Goodreads_Rating" is the ONLY checked Source, then Apply changes.
5. Click on "Download only metadata".
6. When the download is complete, click "Yes".
7. Click "OK" again to save changes and close the Edit Metadata window.
8. Click on the "Run F_rating" icon (looks like an orange starburst).
9. Click on "Set decimal retings." After this processes, you'll see a dialogue box either confirming whether it worked ("Finished extracting rating from publisherfield - for a total of X books") or not ("Finished extracting rating from publisherfield - for a total of 0 books"). Click OK to close the dialogue. Now, in the main calibre window, in each book's row and under the gr_ratings column, you should see a number ranging from 0.0 to 5.0.

!NOTE: When downloading metadata from your usual sources (to get book covers, tags, etc), you'll need to go back to the "Configure Download" window and select your preferred sources. When downloading Goodreads Decimal Ratings, you'll need to repeat the steps to download ONLY from Goodreads_Rating.

ENJOY
Paypal Donations:
  • If you find this plugin useful please feel free to show your appreciation.

Version History:
Spoiler:

2019-12-14
v. 3.0.1. initial version

Attached Files
File Type: zip f_rating3-1.zip (16.6 KB, 1760 views)

Last edited by Pr.BarnArt; 12-25-2019 at 03:32 AM.
Pr.BarnArt is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[GUI Plugin] KindleUnpack - The Plugin DiapDealer Plugins 413 12-18-2019 04:49 PM
[GUI Plugin] Manga plugin mastertea Plugins 0 10-20-2019 03:45 PM
[GUI Plugin] Save Virtual Libraries To Column (GUI) chaley Plugins 8 09-24-2017 10:01 PM
The operator >> is undefined for the argument type(s) float, float twobob Kindle Developer's Corner 10 09-05-2012 01:50 PM
[GUI Plugin] Plugin Updater **Deprecated** kiwidude Plugins 159 06-19-2011 01:27 PM


All times are GMT -4. The time now is 02:22 AM.


MobileRead.com is a privately owned, operated and funded community.