Confusion with Filtered Decks

Hi

I’ve not long been using Anki. I’ve used flashcards before when I was learning Japanese, but now I’m trying to learn all the muscle names for my university course. I’m a bit confused with a lot of the options though. One particular thing has completely lost me with the filtered decks. Basically I want to be able to run through all of my cards from start to finish to test my memory, instead of just going through a few the app shows me each day. Filtered Decks seem to be the solution to this, and works fine for one of my decks, but it’s not for another one.
For instance, my first deck contains 12 cards. My second deck contains 17. However, when I try to make a Filtered Deck out of the second deck, it only adds 10 or so. Why is this? And how can I get them all added? It doesn’t seem to add a filter to all of them. I’ve noticed in the original deck that the ones that aren’t added/filtered just have a due date. Do these need to be completed first or something before they can be filtered? Or is there a way of filtering them? Also, do you have to rebuild the deck every time you finish it, or is there a way of setting it up so you can just restart it from scratch as many times as you want?

Thanks

The standard filter is

deck:"Name of your selected deck"  is:due

You can delete the second part (is:due) if you just want the entire deck. Also note this from the manual:

Filtered decks can not pull in cards that are suspended, buried, or already in a different filtered deck. And unless you are using the experimental scheduler, they can not pull in cards that are in (re)learning. For this reason, a search in the browser may reveal cards that don’t end up in the filtered deck.

And yes, you have to rebuild the deck. But of course, you can just click “Again” if you don’t want a card to leave the Filtered Deck.

Yeah, I usually remove ‘is:due’. :slight_smile:

I’m not sure about the experimental scheduler, but I don’t believe any of them are suspended, buried or in a different filtered deck.

Thanks for the reply.

You can find out easily in the browser. Search for is:suspended, is:buried, is:learn consecutively.
If they are in a learn queue, you will have to enable the new scheduler in the preferences, complete the learning steps in a regular study or reschedule the cards in the browser.

Nope. If I type those in the search box, nothing comes up.

What about is:filtered?

If you search for is:filtered, you have to empty the mentioned decks first. Or search for

deck:"Name of problematic deck"  -is:filtered

to see if there are cards of that deck that didn’t end up in a filtered deck.
Did you search for is:suspended, is:buried and is:learn one after another? It won’t work if you put in multiple of these expressions at once.
Also, for the sake of completeness, make sure the card limit of the filtered deck is high enough.

Okay, I did go through some of the cards that were due last night, and now all of them seem to be under (filtered). So I’m guessing you do have to go through them enough times before they can be filtered. Once I compile a new deck later today, I’ll see how that goes.

And yeah, I searched is:suspended, is:buried, and is:learn one after the other. Also the limit is set to default, so 100.

Nah. This is still confusing the hell out of me. :-\ Whenever I make a filtered collection from an existing deck, the original becomes empty…? Like all the cards are removed. Then if I remove the filtered deck, all the cards are completely removed. Instead, I have to remove the original deck first…? o_O

EDIT: No, I have to remove the filtered deck. I swear I’ve had to remove the original first. As I say - confusing.

EDIT 2: It’s also failed to add all 17 of my cards into my filtered deck again.

The ones that don’t end up in a filtered deck have due dates instead. Is there a way of removing them from the due date and filtering them straight away?

That sounds curious. Maybe you could make a video or at least screenshots of what you’re seeing?
ShareX is quite good for this.

Yeah, I use ShareX. Once I have a moment and I come across the issues again, I’ll take a snap of them.

There is a typo in your post; the sequence of steps to enable the V2 starts with “Finish the cards in learning”.

Oh, it wasn’t meant as a sequence, just three different options to pull in cards from a learn queue.
You might also have to complete the learn steps to switch to the new scheduler (once), but I wasn’t going into details there.

Just a quick question: can you make notes on cards, particularly for the answer sides? It would be good to sometimes leave little notes to help with remembering. :slight_smile: I mean, technically, I could just add it to the answer/Back text box, but I would prefer somewhere/something I can reveal separately.

You can do this with a bit of JavaScript.
Put this code in your back template after creating a field called “Extra” in your note type:

<button id="show-button">Toggle Extra</button>
<br>
<div id="extra" style="display: none;">
{{Extra}}
</div>

<script>
var extra = document.getElementById("extra");
var button = document.getElementById("show-button");
var shown = false;
button.onclick = function() {
	if(!shown) {
		extra.style.display  = "block";
		shown = true;
	}
	else {
		extra.style.display  = "none";
		shown = false;
	}

};

</script>
2 Likes

Oh, that’s smart! Thank you. :smiley: That’s worked a treat.

@abdo Hi again. I’m having a slight problem adding another button. The Notes button I have works perfectly fine, though I now want a second button for more explicit hints. The button and its name show, and the Field and its contents have been added, but clicking on the button doesn’t do anything. All the code is the same, except where it needed changing, such as the name of the button. This is how it’s currently laid out…

{{Front}}

<button id="show-button">Notes</button>
<br>
<div id="extra" style="display: none;">
{{Notes}}
</div>

<script>
var extra = document.getElementById("extra");
var button = document.getElementById("show-button");
var shown = false;
button.onclick = function() {
	if(!shown) {
		extra.style.display  = "block";
		shown = true;
	}
	else {
		extra.style.display  = "none";
		shown = false;
	}

};

</script>

<button id="show-button">Hints</button>
<br>
<div id="extra" style="display: none;">
{{Hints}}
</div>

<script>
var extra = document.getElementById("extra");
var button = document.getElementById("show-button");
var shown = false;
button.onclick = function() {
	if(!shown) {
		extra.style.display  = "block";
		shown = true;
	}
	else {
		extra.style.display  = "none";
		shown = false;
	}

};

</script>

I changed the names. Try it:

{{Front}}
<br>
<button id="show-notes-button">Notes</button>
<br>
<div id="notes" style="display: none;">
{{Notes}}
</div>
<button id="show-hints-button">Hints</button>
<br>
<div id="hints" style="display: none;">
{{Hints}}
</div>

<script>

var notes = document.getElementById("notes");
var showNotesButton = document.getElementById("show-notes-button");
var notesShown = false;
showNotesButton.onclick = function() {
	if(!notesShown) {
		notes.style.display  = "block";
		notesShown = true;
	}
	else {
		notes.style.display  = "none";
		notesShown = false;
	}

};

var hints = document.getElementById("hints");
var showHintsButton = document.getElementById("show-hints-button");
var hintsShown = false;
showHintsButton.onclick = function() {
	if(!hintsShown) {
		hints.style.display  = "block";
		hintsShown = true;
	}
	else {
		hints.style.display  = "none";
		hintsShown = false;
	}

};

</script>

1 Like

@abdo Hi. I keep trying to add that code, but I just get errors in the preview window. :-\

EDIT: Never mind. I think some of the old code got left behind despite selecting it all and deleting it. Made sure the box was completely empty and then added all the code you provided. It’s working now. :slight_smile: