# Average bitrate in folder name

**URL:** https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219
**Category:** General Discussion
**Created:** [April 9, 2009, 4:06pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219 "2009-04-09T16:06:29Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![okram](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/b9bd4f/32.png) [@okram](https://community.mp3tag.de/u/okram)
#### Post date: [April 9, 2009, 4:06pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/1 "2009-04-09T16:06:29Z")

</div>

Hi, I'm looking for the solution to make a mass change of my folder names to include also a bitrate information. Something like this:

if VBR \Dark Side of the Moon [VBR 234]\01 - Breathe  
else \Dark Side of the Moon [320]\01 - Breathe

The following format string does not work  
\%artist%$if("%\_vbr%","VBR","%\_bitrate%")$num(%track%,2) - %title%

What do I do wrong? Thanks!

---

<div class="post-metadata">

### Author: ![drbeachboy](https://community.mp3tag.de/user_avatar/community.mp3tag.de/drbeachboy/32/94_2.png) [@drbeachboy](https://community.mp3tag.de/u/drbeachboy)
#### Post date: [April 9, 2009, 6:01pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/2 "2009-04-09T18:01:02Z")

</div>

Hopefully, this expression should work:

%artist%\%album% '['$if2(%\_vbr%,) %\_bitrate%']'$num(%track%,2) - %title%

---

<div class="post-metadata">

### Author: ![drbeachboy](https://community.mp3tag.de/user_avatar/community.mp3tag.de/drbeachboy/32/94_2.png) [@drbeachboy](https://community.mp3tag.de/u/drbeachboy)
#### Post date: [April 9, 2009, 6:40pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/3 "2009-04-09T18:40:29Z")

</div>

You can also use this one if you really don't want "CBR" in your folder names.

%artist%\%album% '['[$if2($replace(%\_vbr%,CBR),)]%bitrate%']'$num(%track%,2) - %title%

---

<div class="post-metadata">

### Author: ![okram](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/b9bd4f/32.png) [@okram](https://community.mp3tag.de/u/okram)
#### Post date: [April 10, 2009, 1:22pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/4 "2009-04-10T13:22:11Z")

</div>

Sorry but I can't figure it out. It returns something like this (for VBR and CBR):

"\ACDC\The Very Best\01 - Hard As Rock.mp3" -\>  
"\ACDC\The Very Best []\01 - Hard As Rock .mp3"

---

<div class="post-metadata">

### Author: ![drbeachboy](https://community.mp3tag.de/user_avatar/community.mp3tag.de/drbeachboy/32/94_2.png) [@drbeachboy](https://community.mp3tag.de/u/drbeachboy)
#### Post date: [April 10, 2009, 4:22pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/5 "2009-04-10T16:22:21Z")

</div>

What version of LAME are you using? Older versions don't show codec profile information. Neither do some other mp3 encoders. Most of my mp3's are LAME 3.97 through 3.98.2 and the codec profile info is in there, and the tagz info that I gave you yesterday worked fine with those files encoded with the newer versions.

---

<div class="post-metadata">

### Author: ![drbeachboy](https://community.mp3tag.de/user_avatar/community.mp3tag.de/drbeachboy/32/94_2.png) [@drbeachboy](https://community.mp3tag.de/u/drbeachboy)
#### Post date: [April 10, 2009, 4:40pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/6 "2009-04-10T16:40:49Z")

</div>

Try this one:

\%artist%\%album% '['[$replace(%\_vbr%,CBR,)] %\_bitrate%']'$num(%track%,2) - %title%

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [April 10, 2009, 5:00pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/7 "2009-04-10T17:00:06Z")

</div>

The Formatstring

**%TITLE%['['$if($eql(%\_vbr%,'VBR'),'VBR '%\_bitrate%,%\_bitrate%)']']**

results to e. g.  
for CBR: Palomino [128]  
for VBR: Palomino [VBR 233]

... or just even better (based on drbeachboy's example from above)

**[%TITLE%' ']['['[$replace(%\_vbr%' ','CBR ',)]%\_bitrate%']']**

DD.20090410.2120.CEST  
Edit.DD.20120714.1618.CEST

---

<div class="post-metadata">

### Author: ![okram](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/b9bd4f/32.png) [@okram](https://community.mp3tag.de/u/okram)
#### Post date: [April 10, 2009, 5:27pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/8 "2009-04-10T17:27:25Z")

</div>

Hi, thanks! Both last two expressions work, but in case of VBR they create for each file with different bitrate a new folder, so several folders with one file. I thought %\_bitrate% should actually show album average bitrate.

Sorry if I miss something. 🙂

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [April 10, 2009, 5:33pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/9 "2009-04-10T17:33:01Z")

</div>

Mp3tag offers %\_vbr% and %\_bitrate% system variables on a per file basis.

So it makes **no sense** to use these values **when renaming folders**.

DD.20090410.2133.CEST

---

<div class="post-metadata">

### Author: ![okram](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/b9bd4f/32.png) [@okram](https://community.mp3tag.de/u/okram)
#### Post date: [April 10, 2009, 5:42pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/10 "2009-04-10T17:42:43Z")

</div>

> [@DetlevD](#):
>
> Mp3tag offers %\_vbr% and %\_bitrate% system variables on a per file basis.
> 
> So it makes no sense to use these values when renaming folders.
> 
> DD.20090410.2133.CEST

I read that %\_bitrate% also returns the average bitrate of a VBR file in this old thread:

[A few Features that would be nice.](https://community.mp3tag.de/t/1104/1)

Is this still true ?

---

<div class="post-metadata">

### Author: ![okram](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/b9bd4f/32.png) [@okram](https://community.mp3tag.de/u/okram)
#### Post date: [April 19, 2009, 12:04pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/11 "2009-04-19T12:04:06Z")

</div>

> [@okram](#):
>
> I read that %\_bitrate% also returns the average bitrate of a VBR file in this old thread:
> 
> [A few Features that would be nice.](https://community.mp3tag.de/t/1104/1)
> 
> Is this still true ?

Can you please confirm that the quoted post was wrong?

---

<div class="post-metadata">

### Author: ![Florian](https://community.mp3tag.de/user_avatar/community.mp3tag.de/florian/32/5759_2.png) [@Florian](https://community.mp3tag.de/u/Florian)
#### Post date: [April 20, 2009, 7:08am UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/12 "2009-04-20T07:08:38Z")

</div>

It returns the variable bitrate found in a VBRI header.

---

<div class="post-metadata">

### Author: ![garbanzo](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/g/848f3c/32.png) [@garbanzo](https://community.mp3tag.de/u/garbanzo)
#### Post date: [September 24, 2009, 2:51pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/13 "2009-09-24T14:51:51Z")

</div>

so... is average bitrate possible for VBR albums?

i managed to rename CBR fine. but for now, i just set all VBR albums to [VBR].

would love to add average bitrate, but nothing seems to work.

if you have any hints, please let me know!

thanks 🙂

---

<div class="post-metadata">

### Author: ![deafandblind](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/a4c791/32.png) [@deafandblind](https://community.mp3tag.de/u/deafandblind)
#### Post date: [July 14, 2012, 7:56am UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/14 "2012-07-14T07:56:31Z")

</div>

though this thread is a bit old, I just add one expression based on the ones posted above (thanks a lot to everyone here as I have no idea how to write this sort of thing!! 😆 )

if like me you don't want to have your folder name modified (cuz you have other info) and just want the bitrate added to it

e.g:  
Artist - Album - year [Japanese Edition] (remastered 20XX)

becomes

Artist - Album - year [Japanese Edition] (remastered 20XX) [320]

choose: Format value

field: \_directory  
format string: %\_directory% '['$if($eql(%\_vbr%,'VBR'),VBR %\_bitrate%,%\_bitrate%)']'

it worked for me ![:book:](https://community.mp3tag.de/uploads/default/original/1X/0036d5b68f6226c53f6c68abfd0a7b8096fd4505.gif ":book:")

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [July 14, 2012, 11:47am UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/15 "2012-07-14T11:47:34Z")

</div>

> [@deafandblind](#):
>
> though this thread is a bit old ...  
> field: \_directory  
> format string: %\_directory% '['$if($eql(%\_vbr%,'VBR'),VBR %\_bitrate%,%\_bitrate%)']'  
> ... it worked for me ![:book:](https://community.mp3tag.de/uploads/default/original/1X/0036d5b68f6226c53f6c68abfd0a7b8096fd4505.gif ":book:")

Hm, ... it worked for you, but how?

I want to repeat that ...  
[Average bitrate in folder name](https://community.mp3tag.de/t/8219/9)

DD.20120714.1546.CEST

---

<div class="post-metadata">

### Author: ![deafandblind](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/a4c791/32.png) [@deafandblind](https://community.mp3tag.de/u/deafandblind)
#### Post date: [July 24, 2012, 2:44am UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/16 "2012-07-24T02:44:23Z")

</div>

> [@DetlevD](#):
>
> Hm, ... it worked for you, but how?
> 
> I want to repeat that ...  
> [Average bitrate in folder name](https://community.mp3tag.de/t/8219/9)
> 
> DD.20120714.1546.CEST

😆 well this ...i dont know! as I said I just changed one of the xpression here a wee bit... but it still works well, I've used it for a while now and use it almost everyday.  
all the other expression I used from here were always modifying the name of my folder, which as I explained is something i dont want.

why do you think it shouldnt work (if it's not too technical explain)? or what's the problem...I'm not too sure what your link was intended at...

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [July 24, 2012, 3:28am UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/17 "2012-07-24T03:28:47Z")

</div>

> [@deafandblind](#):
>
> ... I just changed one of the xpression here a wee bit... but it still works well, I've used it for a while now and use it almost everyday. ...  
> all the other expression I used from here were always modifying the name of my folder, which as I explained is something i dont want.  
> why do you think it shouldnt work (if it's not too technical explain)? or what's the problem...I'm not too sure what your link was intended at...

I understand that you got no problems when renaming a folder in the path to the media file with an appended number of CBR or VBR by formatting the pseudo tag-field \_DIRECTORY.

Other user reported problems.  
Read there ...  
[Need help with Directory naming action](https://community.mp3tag.de/t/1900/1)

DD.20120724.0722.CEST

---

<div class="post-metadata">

### Author: ![deafandblind](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/a4c791/32.png) [@deafandblind](https://community.mp3tag.de/u/deafandblind)
#### Post date: [July 29, 2012, 8:31am UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/18 "2012-07-29T08:31:11Z")

</div>

> [@DetlevD](#):
>
> I understand that you got no problems when renaming a folder in the path to the media file with an appended number of CBR or VBR by formatting the pseudo tag-field \_DIRECTORY.
> 
> Other user reported problems.  
> Read there ...  
> [Need help with Directory naming action](https://community.mp3tag.de/t/1900/1)
> 
> DD.20120724.0722.CEST

what's explained in this link of yours is rather different from what I do... I just want the bitrate added and my folder unchanged as I said, ...they want to use tag info to create some sort of a foldername template... whatsoever, I have no problem no matter whether the files are CBR or VBR and that's all that matters to me, so if like me people want to add the bitrate and leave all other things unchanged, this expression is great! ![:music:](https://community.mp3tag.de/uploads/default/original/1X/2ba05d1ade5eb0d15fc173be6f717dbe63890a70.gif ":music:")

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [July 29, 2012, 2:36pm UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/19 "2012-07-29T14:36:38Z")

</div>

> [@deafandblind](#):
>
> ... I just want the bitrate added and my folder unchanged as I said, ... I have no problem no matter whether the files are CBR or VBR ...

Maybe I have misunderstood your words in post#14 within this thread ...  
[Average bitrate in folder name](https://community.mp3tag.de/t/8219/14)

I want to mention that using a dynamic value like VBR in the name of a folder within a folderpath, when writing to the pseudo tag-field \_DIRECTORY, this will result in several new folders, one per each VBR value.  
Previously it was certainly always the case ... but maybe I am wrong.  
Well, you can check it out for yourself.

DD.20120729.1833.CEST

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [July 30, 2012, 4:54am UTC](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219/20 "2012-07-30T04:54:02Z")

</div>

> [@DetlevD](#):
>
> I want to mention that using a dynamic value like VBR in the name of a folder within a folderpath, when writing to the pseudo tag-field \_DIRECTORY, this will result in several new folders, one per each VBR value.

No, \_DIRECTORY renames the current folder, it does not create new folders. So it works fine for this purpose.

Although it renames the folder with the bitrate of the first file, not the average bitrate of the whole folder. That's not possible without some extra steps with the export tool.

[Next page](https://community.mp3tag.de/t/average-bitrate-in-folder-name/8219.md?page=2)
